From 934b50da62ff57be76e0e98aa4c56b2b8c00c249 Mon Sep 17 00:00:00 2001 From: OmarHatem Date: Tue, 30 Dec 2025 15:27:47 +0100 Subject: [PATCH] await wallet name check [skip ci] --- lib/core/wallet_creation_service.dart | 6 +++--- lib/view_model/wallet_creation_vm.dart | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/core/wallet_creation_service.dart b/lib/core/wallet_creation_service.dart index 7f09e7bfb..51f1b288f 100644 --- a/lib/core/wallet_creation_service.dart +++ b/lib/core/wallet_creation_service.dart @@ -97,7 +97,7 @@ class WalletCreationService { } Future restoreFromKeys(WalletCredentials credentials, {bool? isTestnet}) async { - checkIfExists(credentials.name); + await checkIfExists(credentials.name); if (credentials.password == null) { credentials.password = generateWalletPassword(); @@ -116,7 +116,7 @@ class WalletCreationService { } Future restoreFromSeed(WalletCredentials credentials, {bool? isTestnet}) async { - checkIfExists(credentials.name); + await checkIfExists(credentials.name); if (credentials.password == null) { credentials.password = generateWalletPassword(); @@ -135,7 +135,7 @@ class WalletCreationService { } Future restoreFromHardwareWallet(WalletCredentials credentials) async { - checkIfExists(credentials.name); + await checkIfExists(credentials.name); final password = generateWalletPassword(); credentials.password = password; await keyService.saveWalletPassword(password: password, walletName: credentials.name); diff --git a/lib/view_model/wallet_creation_vm.dart b/lib/view_model/wallet_creation_vm.dart index 60918051c..fdc912006 100644 --- a/lib/view_model/wallet_creation_vm.dart +++ b/lib/view_model/wallet_creation_vm.dart @@ -95,7 +95,7 @@ abstract class WalletCreationVMBase with Store { throw Exception(S.current.repeated_password_is_incorrect); } - walletCreationService.checkIfExists(name); + await walletCreationService.checkIfExists(name); final dirPath = await pathForWalletDir(name: name, type: type); final path = await pathForWallet(name: name, type: type);