Remove duplicate code

Cut-n-paste somehow into the same class
This commit is contained in:
Neil Booth 2016-01-01 22:57:21 +09:00
parent c3df5c7177
commit cf4ee487cd
1 changed files with 0 additions and 18 deletions

View File

@ -337,21 +337,3 @@ class TrezorCompatiblePlugin(BasePlugin):
@staticmethod
def is_valid_seed(seed):
return True
def on_restore_wallet(self, wallet, wizard):
assert isinstance(wallet, self.wallet_class)
msg = _("Enter the seed for your %s wallet:" % self.device)
seed = wizard.request_seed(msg, is_valid = self.is_valid_seed)
# Restored wallets are not hardware wallets
wallet_class = self.wallet_class.restore_wallet_class
wallet.storage.put('wallet_type', wallet_class.wallet_type)
wallet = wallet_class(wallet.storage)
passphrase = wizard.request_passphrase(self.device, restore=True)
password = wizard.request_password()
wallet.add_seed(seed, password)
wallet.add_cosigner_seed(seed, 'x/', password, passphrase)
wallet.create_main_account(password)
return wallet