diff --git a/CHANGELOG.md b/CHANGELOG.md index f62dbd72..9c2ff2ef 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +# 2.1.1 - 2025-07-19 + +### Fixed + +- Routing error on startup + # 2.1.0 - 2025-07-18 ### Added diff --git a/fastlane/metadata/android/en-US/changelogs/300.txt b/fastlane/metadata/android/en-US/changelogs/300.txt new file mode 100644 index 00000000..dd45f66f --- /dev/null +++ b/fastlane/metadata/android/en-US/changelogs/300.txt @@ -0,0 +1,2 @@ +FIXED +- Routing error on startup \ No newline at end of file diff --git a/fastlane/metadata/android/fr-FR/changelogs/300.txt b/fastlane/metadata/android/fr-FR/changelogs/300.txt new file mode 100644 index 00000000..720bdab2 --- /dev/null +++ b/fastlane/metadata/android/fr-FR/changelogs/300.txt @@ -0,0 +1,2 @@ +CORRIGÉ +- Erreur de redirection au démarrage \ No newline at end of file diff --git a/lib/common/actions/notes/add.dart b/lib/common/actions/notes/add.dart index b1322a7e..2f5afadf 100644 --- a/lib/common/actions/notes/add.dart +++ b/lib/common/actions/notes/add.dart @@ -57,6 +57,5 @@ Future addNote(BuildContext context, WidgetRef ref, {required NoteType not } final EditorPageExtra extra = (readOnly: false, isNewNote: true); - await context.pushNamed(NavigationRoute.editor.name, extra: extra); } diff --git a/lib/navigation/router.dart b/lib/navigation/router.dart index 658294c0..d17cb05a 100644 --- a/lib/navigation/router.dart +++ b/lib/navigation/router.dart @@ -41,14 +41,14 @@ String? goRouterRedirect(BuildContext context, GoRouterState state) { final isLocked = lockAppNotifier.value; if (!lockApp) { - return null; - } + if (state.matchedLocation == '/') { + return NavigationRoute.notes.path; + } - if (isLocked && state.matchedLocation != NavigationRoute.lock.path) { + return null; + } else if (isLocked && state.matchedLocation != NavigationRoute.lock.path) { return NavigationRoute.lock.path; - } - - if (!isLocked && state.matchedLocation == NavigationRoute.lock.path) { + } else if (!isLocked && state.matchedLocation == NavigationRoute.lock.path) { return NavigationRoute.notes.path; } diff --git a/pubspec.yaml b/pubspec.yaml index b2f1c5f1..7681fc38 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -2,7 +2,7 @@ name: localmaterialnotes description: Simple, local, material design notes repository: https://github.com/maelchiotti/LocalMaterialNotes -version: 2.1.0+29 +version: 2.1.1+30 publish_to: none environment: