diff --git a/lib/src/screens/auth/auth_page.dart b/lib/src/screens/auth/auth_page.dart index 79130b89d..b5800a874 100644 --- a/lib/src/screens/auth/auth_page.dart +++ b/lib/src/screens/auth/auth_page.dart @@ -1,6 +1,5 @@ import 'package:another_flushbar/flushbar.dart'; import 'package:cake_wallet/utils/show_bar.dart'; -import 'package:cake_wallet/utils/show_pop_up.dart'; import 'package:mobx/mobx.dart'; import 'package:flutter/material.dart'; import 'package:flutter/cupertino.dart'; @@ -10,8 +9,6 @@ import 'package:cake_wallet/view_model/auth_view_model.dart'; import 'package:cake_wallet/src/screens/pin_code/pin_code.dart'; import 'package:cake_wallet/src/screens/pin_code/pin_code_widget.dart'; import 'package:cake_wallet/core/execution_state.dart'; -import 'package:cake_wallet/src/widgets/alert_with_two_actions.dart'; -import 'package:flutter/services.dart'; typedef OnAuthenticationFinished = void Function(bool, AuthPageState); @@ -64,7 +61,9 @@ class AuthPagePinCodeStateImpl extends AuthPageState { WidgetsBinding.instance.addPostFrameCallback((_) async { _pinCodeKey.currentState?.clear(); dismissFlushBar(_authBar); - showBar(context, S.of(context).failed_authentication(state.error)); + if (context.mounted) { + showBar(context, S.of(context).failed_authentication(state.error)); + } widget.onAuthenticationFinished(false, this); }); } @@ -89,23 +88,6 @@ class AuthPagePinCodeStateImpl extends AuthPageState { super.initState(); } - Future _showSeedsPopup(BuildContext context, String message) async { - await showPopUp( - context: context, - builder: (BuildContext context) { - return AlertWithTwoActions( - alertTitle: "Corrupted seeds", - alertContent: message, - leftButtonText: S.of(context).copy, - rightButtonText: S.of(context).ok, - actionLeftButton: () async { - await Clipboard.setData(ClipboardData(text: message)); - }, - actionRightButton: () => Navigator.of(context).pop(), - ); - }); - } - @override void dispose() { _reaction?.reaction.dispose(); diff --git a/lib/src/screens/dashboard/sign_page.dart b/lib/src/screens/dashboard/sign_page.dart index c9f188fe9..688e9fe27 100644 --- a/lib/src/screens/dashboard/sign_page.dart +++ b/lib/src/screens/dashboard/sign_page.dart @@ -159,12 +159,14 @@ class SignPage extends BasePage { WidgetsBinding.instance.addPostFrameCallback((_) { showPopUp( context: context, - builder: (_) { + builder: (_context) { return AlertWithOneAction( alertTitle: S.current.successful, alertContent: S.current.message_verified, - buttonText: S.of(context).ok, - buttonAction: () => Navigator.of(context).pop(), + buttonText: S.of(_context).ok, + buttonAction: () { + if (_context.mounted) Navigator.of(_context).pop(); + }, ); }); }); diff --git a/scripts/windows/build_exe_installer.iss b/scripts/windows/build_exe_installer.iss index 1425b614b..dd7c5e7ca 100644 --- a/scripts/windows/build_exe_installer.iss +++ b/scripts/windows/build_exe_installer.iss @@ -1,5 +1,5 @@ #define MyAppName "Cake Wallet" -#define MyAppVersion "5.1.2" +#define MyAppVersion "5.2.0" #define MyAppPublisher "Cake Labs LLC" #define MyAppURL "https://cakewallet.com/" #define MyAppExeName "CakeWallet.exe"