diff --git a/lib/src/screens/auth/auth_page.dart b/lib/src/screens/auth/auth_page.dart index db5e3cd4a..0b3b8511a 100644 --- a/lib/src/screens/auth/auth_page.dart +++ b/lib/src/screens/auth/auth_page.dart @@ -111,15 +111,16 @@ class AuthPageState extends State { throw Exception('Key context is null. Should be not happened'); } - WidgetsBinding.instance.addPostFrameCallback((_) async { - await _authBar?.dismiss(); - await _progressBar?.dismiss(); - - if (route != null) { - Navigator.of(_key.currentContext!).pushReplacementNamed(route); - } else { - Navigator.of(_key.currentContext!).pop(); - } + WidgetsBinding.instance.addPostFrameCallback((_) { + dismissFlushBar(_authBar); + dismissFlushBar(_progressBar); + WidgetsBinding.instance.addPostFrameCallback((_) { + if (route != null) { + Navigator.of(_key.currentContext!).pushReplacementNamed(route); + } else { + Navigator.of(_key.currentContext!).pop(); + } + }); }); }