CAKE-312 | wrapped unlock page by WillPopScope; fixed biometricAuth() in the auth_view_model.dart
OleksandrSobol committed
Apr 22, 2021 at 18:56 UTC
bbe75451a479a12652f6828920a0d35a47a82d63
2 files changed
+5
-5
lib/router.dart
+5
-3
@@ -237,9 +237,11 @@ Route<dynamic> createRoute(RouteSettings settings) {
237
case Routes.unlock:
238
return MaterialPageRoute<void>(
239
fullscreenDialog: true,
240
- builder: (_) => getIt.get<AuthPage>(
241
- param1: settings.arguments as OnAuthenticationFinished,
242
- param2: false));
240
+ builder: (_) => WillPopScope(
241
+ child: getIt.get<AuthPage>(
242
+ param1: settings.arguments as OnAuthenticationFinished,
243
+ param2: false),
244
+ onWillPop: () async => false));
245
246
case Routes.nodeList:
247
return CupertinoPageRoute<void>(
lib/view_model/auth_view_model.dart
-2
@@ -110,8 +110,6 @@ abstract class AuthViewModelBase with Store {
110
111
if (isAuthenticated) {
112
state = ExecutedSuccessfullyState();
113
- } else {
114
- state = FailureState('Failure biometric authentication');
113
}
114
}
115
} catch(e) {