Fix deprecation message for GoRouterState.namedLocation (#3092)

Fix deprecation message for `GoRouterState.namedLocation` -- it should
point to `GoRouter.of(context).namedLocation`, not
`GoRouter.of(context).routeInformationParser.namedLocation` (the latter
does not exist).

Previously mentioned here: bdc07b69d4 (r88804919)
This commit is contained in:
Jørgen P. Tjernø
2023-02-17 14:53:26 -08:00
committed by GitHub
parent 6e4431f16d
commit 9747469b94
3 changed files with 6 additions and 3 deletions

View File

@ -1,3 +1,7 @@
## 6.0.9
- Fixes deprecation message for `GoRouterState.namedLocation`
## 6.0.8
* Adds support for Iterables, Lists and Sets in query params for TypedGoRoute. [#108437](https://github.com/flutter/flutter/issues/108437).

View File

@ -122,8 +122,7 @@ class GoRouterState {
/// Get a location from route name and parameters.
/// This is useful for redirecting to a named location.
@Deprecated(
'Uses GoRouter.of(context).routeInformationParser.namedLocation instead')
@Deprecated('Use GoRouter.of(context).namedLocation instead')
String namedLocation(
String name, {
Map<String, String> params = const <String, String>{},

View File

@ -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: 6.0.8
version: 6.0.9
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