follow up previous commit

This commit is contained in:
ThomasV 2016-08-25 12:28:06 +02:00
parent 3ac357171a
commit 3a56b00da7
1 changed files with 5 additions and 3 deletions

View File

@ -120,11 +120,12 @@ def run_non_RPC(config):
passphrase = config.get('passphrase', '')
password = password_dialog() if keystore.is_private(text) else None
if keystore.is_seed(text):
k = keystore.from_seed(text, passphrase, password)
k = keystore.from_seed(text, passphrase)
elif keystore.is_any_key(text):
k = keystore.from_keys(text, password)
k = keystore.from_keys(text)
else:
sys.exit(str(e))
k.update_password(None, password)
storage.put('keystore', k.dump())
storage.put('wallet_type', 'standard')
storage.put('use_encryption', bool(password))
@ -146,7 +147,8 @@ def run_non_RPC(config):
password = password_dialog()
passphrase = config.get('passphrase', '')
seed = Mnemonic('en').make_seed()
k = keystore.from_seed(seed, passphrase, password)
k = keystore.from_seed(seed, passphrase)
k.update_password(None, password)
storage.put('keystore', k.dump())
storage.put('wallet_type', 'standard')
storage.put('use_encryption', bool(password))