Browse Source

restore from addresses (fix #2173)

283
ThomasV 8 years ago
parent
commit
776f09b50e
  1. 7
      electrum

7
electrum

@ -97,7 +97,7 @@ if is_bundle or is_local or is_android:
from electrum import bitcoin, network
from electrum import SimpleConfig, Network
from electrum.wallet import Wallet
from electrum.wallet import Wallet, Imported_Wallet
from electrum.storage import WalletStorage
from electrum.util import print_msg, print_stderr, json_encode, json_decode
from electrum.util import set_verbosity, InvalidPassword, check_www_dir
@ -134,6 +134,11 @@ def run_non_RPC(config):
text = config.get('text').strip()
passphrase = config.get('passphrase', '')
password = password_dialog() if keystore.is_private(text) else None
if keystore.is_address_list(text):
wallet = Imported_Wallet(storage)
for x in text.split():
wallet.import_address(x)
else:
if keystore.is_seed(text):
k = keystore.from_seed(text, passphrase)
elif keystore.is_any_key(text):

Loading…
Cancel
Save