mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-10-17 05:41:29 +02:00
Add Exception handler to report loading wallet issues
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import 'package:cake_wallet/routes.dart';
|
||||
import 'package:cake_wallet/utils/exception_handler.dart';
|
||||
import 'package:flutter/widgets.dart';
|
||||
import 'package:mobx/mobx.dart';
|
||||
import 'package:cake_wallet/entities/load_current_wallet.dart';
|
||||
@@ -16,8 +17,9 @@ void startAuthenticationStateChange(AuthenticationStore authenticationStore,
|
||||
if (state == AuthenticationState.installed) {
|
||||
try {
|
||||
await loadCurrentWallet();
|
||||
} catch (e) {
|
||||
loginError = e;
|
||||
} catch (error, stack) {
|
||||
loginError = error;
|
||||
ExceptionHandler.onError(FlutterErrorDetails(exception: error, stack: stack));
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user