Skip to content
Snippets Groups Projects
Commit d62691d6 authored by poka's avatar poka
Browse files

fix: null balance deleting check

parent fd5504ea
No related branches found
No related tags found
No related merge requests found
Pipeline #16015 failed
...@@ -500,7 +500,8 @@ class WalletOptions extends StatelessWidget { ...@@ -500,7 +500,8 @@ class WalletOptions extends StatelessWidget {
_hasConsumers.hasError) { _hasConsumers.hasError) {
return const Text(''); return const Text('');
} }
final double _balance = balanceCache[walletProvider.address.text]!; final double _balance =
balanceCache[walletProvider.address.text] ?? 0;
final bool canDelete = !isDefaultWallet && final bool canDelete = !isDefaultWallet &&
!_hasConsumers.data! && !_hasConsumers.data! &&
(_balance > 2 || _balance == 0); (_balance > 2 || _balance == 0);
......
...@@ -5,7 +5,7 @@ description: Pay with G1. ...@@ -5,7 +5,7 @@ description: Pay with G1.
# pub.dev using `pub publish`. This is preferred for private packages. # pub.dev using `pub publish`. This is preferred for private packages.
publish_to: 'none' # Remove this line if you wish to publish to pub.dev publish_to: 'none' # Remove this line if you wish to publish to pub.dev
version: 0.0.8+6 version: 0.0.8+7
environment: environment:
sdk: '>=2.12.0 <3.0.0' sdk: '>=2.12.0 <3.0.0'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment