fix #6605
This commit is contained in:
@@ -248,18 +248,21 @@ class InstallWizard(QDialog, MessageBoxMixin, BaseWizard):
|
|||||||
nonlocal temp_storage
|
nonlocal temp_storage
|
||||||
temp_storage = None
|
temp_storage = None
|
||||||
msg = None
|
msg = None
|
||||||
path = os.path.join(wallet_folder, filename)
|
if filename:
|
||||||
wallet_from_memory = get_wallet_from_daemon(path)
|
path = os.path.join(wallet_folder, filename)
|
||||||
try:
|
wallet_from_memory = get_wallet_from_daemon(path)
|
||||||
if wallet_from_memory:
|
try:
|
||||||
temp_storage = wallet_from_memory.storage # type: Optional[WalletStorage]
|
if wallet_from_memory:
|
||||||
else:
|
temp_storage = wallet_from_memory.storage # type: Optional[WalletStorage]
|
||||||
temp_storage = WalletStorage(path)
|
else:
|
||||||
except (StorageReadWriteError, WalletFileException) as e:
|
temp_storage = WalletStorage(path)
|
||||||
msg = _('Cannot read file') + f'\n{repr(e)}'
|
except (StorageReadWriteError, WalletFileException) as e:
|
||||||
except Exception as e:
|
msg = _('Cannot read file') + f'\n{repr(e)}'
|
||||||
self.logger.exception('')
|
except Exception as e:
|
||||||
msg = _('Cannot read file') + f'\n{repr(e)}'
|
self.logger.exception('')
|
||||||
|
msg = _('Cannot read file') + f'\n{repr(e)}'
|
||||||
|
else:
|
||||||
|
msg = _('')
|
||||||
self.next_button.setEnabled(temp_storage is not None)
|
self.next_button.setEnabled(temp_storage is not None)
|
||||||
user_needs_to_enter_password = False
|
user_needs_to_enter_password = False
|
||||||
if temp_storage:
|
if temp_storage:
|
||||||
|
|||||||
Reference in New Issue
Block a user