mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2025-02-02 19:26:27 +00:00
Add Exception handler to report loading wallet issues
This commit is contained in:
parent
7b35604ff5
commit
37ea2d341f
1 changed files with 4 additions and 2 deletions
|
@ -1,4 +1,5 @@
|
||||||
import 'package:cake_wallet/routes.dart';
|
import 'package:cake_wallet/routes.dart';
|
||||||
|
import 'package:cake_wallet/utils/exception_handler.dart';
|
||||||
import 'package:flutter/widgets.dart';
|
import 'package:flutter/widgets.dart';
|
||||||
import 'package:mobx/mobx.dart';
|
import 'package:mobx/mobx.dart';
|
||||||
import 'package:cake_wallet/entities/load_current_wallet.dart';
|
import 'package:cake_wallet/entities/load_current_wallet.dart';
|
||||||
|
@ -16,8 +17,9 @@ void startAuthenticationStateChange(AuthenticationStore authenticationStore,
|
||||||
if (state == AuthenticationState.installed) {
|
if (state == AuthenticationState.installed) {
|
||||||
try {
|
try {
|
||||||
await loadCurrentWallet();
|
await loadCurrentWallet();
|
||||||
} catch (e) {
|
} catch (error, stack) {
|
||||||
loginError = e;
|
loginError = error;
|
||||||
|
ExceptionHandler.onError(FlutterErrorDetails(exception: error, stack: stack));
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue