mirror of
https://github.com/the-djmaze/snappymail.git
synced 2025-01-01 04:22:15 +08:00
Don't remember OpenPGP key passphrase when it fails #840
This commit is contained in:
parent
78938caaf3
commit
acc1c0badc
1 changed files with 7 additions and 6 deletions
|
@ -31,12 +31,13 @@ const
|
||||||
'OPENPGP/'+btnTxt
|
'OPENPGP/'+btnTxt
|
||||||
);
|
);
|
||||||
if (pass) {
|
if (pass) {
|
||||||
pass.remember && passphrases.set(key, pass.password);
|
const passphrase = pass.password,
|
||||||
let passphrase = pass.password;
|
result = await openpgp.decryptKey({
|
||||||
return await openpgp.decryptKey({
|
privateKey: privateKey.key,
|
||||||
privateKey: privateKey.key,
|
passphrase
|
||||||
passphrase
|
});
|
||||||
});
|
result && pass.remember && passphrases.set(key, passphrase);
|
||||||
|
return result;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue