temporary fix wallet constructors
This commit is contained in:
@@ -70,7 +70,7 @@ def init_plugins(config, is_local, gui_name):
|
|||||||
|
|
||||||
def register_wallet_type(name, x):
|
def register_wallet_type(name, x):
|
||||||
import wallet
|
import wallet
|
||||||
x += (lambda storage: plugin_loader(config, name).constructor(storage),)
|
x += (lambda: plugin_loader(config, name),)
|
||||||
wallet.wallet_types.append(x)
|
wallet.wallet_types.append(x)
|
||||||
|
|
||||||
descriptions = electrum_plugins.descriptions
|
descriptions = electrum_plugins.descriptions
|
||||||
|
|||||||
@@ -1927,7 +1927,10 @@ class Wallet(object):
|
|||||||
if wallet_type:
|
if wallet_type:
|
||||||
for cat, t, name, loader in wallet_types:
|
for cat, t, name, loader in wallet_types:
|
||||||
if t == wallet_type:
|
if t == wallet_type:
|
||||||
WalletClass = loader
|
if cat in ['hardware', 'twofactor']:
|
||||||
|
WalletClass = lambda storage: apply(loader().constructor, (storage,))
|
||||||
|
else:
|
||||||
|
WalletClass = loader
|
||||||
break
|
break
|
||||||
else:
|
else:
|
||||||
if re.match('(\d+)of(\d+)', wallet_type):
|
if re.match('(\d+)of(\d+)', wallet_type):
|
||||||
|
|||||||
Reference in New Issue
Block a user