[go_router] Adds missed popping log (#1931)
Co-authored-by: John Ryan <ryjohn@google.com>
diff --git a/packages/go_router/CHANGELOG.md b/packages/go_router/CHANGELOG.md
index 562c74a..897e856 100644
--- a/packages/go_router/CHANGELOG.md
+++ b/packages/go_router/CHANGELOG.md
@@ -1,3 +1,7 @@
+## 4.0.3
+
+- Adds missed popping log.
+
## 4.0.2
- Fixes a bug where initialLocation took precedence over deep-links
diff --git a/packages/go_router/lib/src/go_router.dart b/packages/go_router/lib/src/go_router.dart
index 7afc5fa..a57c9b7 100644
--- a/packages/go_router/lib/src/go_router.dart
+++ b/packages/go_router/lib/src/go_router.dart
@@ -161,7 +161,13 @@
);
/// Pop the top page off the GoRouter's page stack.
- void pop() => routerDelegate.pop();
+ void pop() {
+ assert(() {
+ log.info('popping $location');
+ return true;
+ }());
+ routerDelegate.pop();
+ }
/// Refresh the route.
void refresh() {
diff --git a/packages/go_router/pubspec.yaml b/packages/go_router/pubspec.yaml
index cf9c4ef..f3b1923 100644
--- a/packages/go_router/pubspec.yaml
+++ b/packages/go_router/pubspec.yaml
@@ -1,7 +1,7 @@
name: go_router
description: A declarative router for Flutter based on Navigation 2 supporting
deep linking, data-driven routes and more
-version: 4.0.2
+version: 4.0.3
repository: https://github.com/flutter/packages/tree/main/packages/go_router
issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+go_router%22