trezor: single passphrase entry
Only require the user to input the passphrase once, unless creating a wallet. Should they mis-enter the passphrase, they will be warned Electrum couldn't pair the device, and when they actually need to use it they will be prompted again. Fixes #1672
This commit is contained in:
@@ -24,7 +24,8 @@ class TrezorCompatibleWallet(BIP44_HW_Wallet):
|
||||
def get_public_key(self, bip32_path):
|
||||
client = self.get_client()
|
||||
address_n = client.expand_path(bip32_path)
|
||||
node = client.get_public_node(address_n).node
|
||||
creating = self.next_account_number() == 0
|
||||
node = client.get_public_node(address_n, creating).node
|
||||
xpub = ("0488B21E".decode('hex') + chr(node.depth)
|
||||
+ self.i4b(node.fingerprint) + self.i4b(node.child_num)
|
||||
+ node.chain_code + node.public_key)
|
||||
|
||||
Reference in New Issue
Block a user