mirror of
https://github.com/LBRYFoundation/LBRY-Vault.git
synced 2025-09-03 02:35:20 +00:00
Handle invalid PIN on exporting private key
Prevent Android App from crashing when a wrong PIN is entered.
This commit is contained in:
parent
53fc343b4a
commit
d5e20d607e
1 changed files with 6 additions and 2 deletions
|
@ -928,6 +928,10 @@ class ElectrumWindow(App):
|
||||||
return
|
return
|
||||||
if not self.wallet.can_export():
|
if not self.wallet.can_export():
|
||||||
return
|
return
|
||||||
key = str(self.wallet.export_private_key(addr, password)[0])
|
try:
|
||||||
pk_label.data = key
|
key = str(self.wallet.export_private_key(addr, password)[0])
|
||||||
|
pk_label.data = key
|
||||||
|
except InvalidPassword:
|
||||||
|
self.show_error("Invalid PIN")
|
||||||
|
return
|
||||||
self.protected(_("Enter your PIN code in order to decrypt your private key"), show_private_key, (addr, pk_label))
|
self.protected(_("Enter your PIN code in order to decrypt your private key"), show_private_key, (addr, pk_label))
|
||||||
|
|
Loading…
Add table
Reference in a new issue