Showing
1 changed file
with
1 additions
and
1 deletions
| @@ -519,7 +519,7 @@ Esses middlewares serão executados nesta ordem: **-8 => 2 => 4 => 5** | @@ -519,7 +519,7 @@ Esses middlewares serão executados nesta ordem: **-8 => 2 => 4 => 5** | ||
| 519 | Esta função será chamada quando a página da rota chamada estiver sendo pesquisada. RouteSettings se torna o resultado do redirecionamento. Ou retorne nulo e não haverá redirecionamento. | 519 | Esta função será chamada quando a página da rota chamada estiver sendo pesquisada. RouteSettings se torna o resultado do redirecionamento. Ou retorne nulo e não haverá redirecionamento. | 
| 520 | 520 | ||
| 521 | ```dart | 521 | ```dart | 
| 522 | -GetPage redirect( ) { | 522 | +RouteSettings redirect(String route) { | 
| 523 | final authService = Get.find<AuthService>(); | 523 | final authService = Get.find<AuthService>(); | 
| 524 | return authService.authed.value ? null : RouteSettings(name: '/login') | 524 | return authService.authed.value ? null : RouteSettings(name: '/login') | 
| 525 | } | 525 | } | 
- 
Please register or login to post a comment