tThe constructor() concept doesn't exist - electrum - Electrum Bitcoin wallet HTML git clone https://git.parazyd.org/electrum DIR Log DIR Files DIR Refs DIR Submodules --- DIR commit 0f70d0b8a58340481dd0aa00a0f9b6e69a8bbdcf DIR parent 993ff30616aeb4013d8fdd0c67ca7e04409a2d68 HTML Author: Neil Booth <kyuupichan@gmail.com> Date: Tue, 29 Dec 2015 22:59:25 +0900 The constructor() concept doesn't exist Did it ever? Diffstat: M lib/wallet.py | 5 +---- M plugins/ledger/ledger.py | 3 --- M plugins/trezor/plugin.py | 3 --- M plugins/trustedcoin/trustedcoin.py | 3 --- 4 files changed, 1 insertion(+), 13 deletions(-) --- DIR diff --git a/lib/wallet.py b/lib/wallet.py t@@ -1916,10 +1916,7 @@ class Wallet(object): if wallet_type: for cat, t, name, loader in wallet_types: if t == wallet_type: - if cat in ['hardware', 'twofactor']: - WalletClass = lambda storage: apply(loader().constructor, (storage,)) - else: - WalletClass = loader + WalletClass = loader break else: if re.match('(\d+)of(\d+)', wallet_type): DIR diff --git a/plugins/ledger/ledger.py b/plugins/ledger/ledger.py t@@ -424,9 +424,6 @@ class LedgerPlugin(BasePlugin): self.wallet = None self.handler = None - def constructor(self, s): - return BTChipWallet(s) - def is_enabled(self): if not BTCHIP: return False DIR diff --git a/plugins/trezor/plugin.py b/plugins/trezor/plugin.py t@@ -158,9 +158,6 @@ class TrezorCompatiblePlugin(BasePlugin): self.handler = None self.client = None - def constructor(self, s): - return self.wallet_class(s) - def give_error(self, message): self.print_error(message) raise Exception(message) DIR diff --git a/plugins/trustedcoin/trustedcoin.py b/plugins/trustedcoin/trustedcoin.py t@@ -276,9 +276,6 @@ class TrustedCoinPlugin(BasePlugin): BasePlugin.__init__(self, parent, config, name) self.seed_func = lambda x: bitcoin.is_new_seed(x, SEED_PREFIX) - def constructor(self, s): - return Wallet_2fa(s) - def is_available(self): return True