mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-12-22 06:18:07 +00:00
client: improve passphrase state handling
This commit is contained in:
parent
2733fae057
commit
832c47a278
@ -165,8 +165,11 @@ class TrezorClient:
|
||||
self.call_raw(messages.Cancel())
|
||||
raise ValueError("Passphrase too long")
|
||||
|
||||
resp = self.call_raw(messages.PassphraseAck(passphrase=passphrase))
|
||||
resp = self.call_raw(
|
||||
messages.PassphraseAck(passphrase=passphrase, state=self.state)
|
||||
)
|
||||
if isinstance(resp, messages.PassphraseStateRequest):
|
||||
# TODO report to the user that the passphrase has changed?
|
||||
self.state = resp.state
|
||||
return self.call_raw(messages.PassphraseStateAck())
|
||||
else:
|
||||
|
Loading…
Reference in New Issue
Block a user