eth token refresh fix

This commit is contained in:
julian 2024-01-15 10:34:22 -06:00
parent 5de3723752
commit 1cd7289fe2

View file

@ -62,27 +62,7 @@ class _RefreshButtonState extends ConsumerState<WalletRefreshButton> {
_syncStatusSubscription =
eventBus.on<WalletSyncStatusChangedEvent>().listen(
(event) async {
if (event.walletId == widget.walletId &&
widget.tokenContractAddress == null) {
switch (event.newStatus) {
case WalletSyncStatus.unableToSync:
if (_spinController.hasLoadedAnimation) {
_spinController.stop?.call();
}
break;
case WalletSyncStatus.synced:
if (_spinController.hasLoadedAnimation) {
_spinController.stop?.call();
}
break;
case WalletSyncStatus.syncing:
if (_spinController.hasLoadedAnimation) {
_spinController.repeat?.call();
}
break;
}
} else if (widget.tokenContractAddress != null &&
event.walletId == widget.walletId + widget.tokenContractAddress!) {
if (event.walletId == widget.walletId) {
switch (event.newStatus) {
case WalletSyncStatus.unableToSync:
if (_spinController.hasLoadedAnimation) {