mirror of
https://github.com/moparisthebest/mail
synced 2025-01-10 13:07:59 -05:00
catch error in pgp decryption
This commit is contained in:
parent
cdd467f4bd
commit
da7d42cb33
@ -223,6 +223,14 @@ define(function(require) {
|
||||
openpgp.decryptAndVerifyMessage(this._privateKey, [publicKey], message, onDecrypted);
|
||||
|
||||
function onDecrypted(err, decrypted) {
|
||||
if (err) {
|
||||
callback({
|
||||
errMsg: 'Error decrypting PGP message!',
|
||||
err: err
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
// check if signatures are valid
|
||||
signaturesValid = true;
|
||||
decrypted.signatures.forEach(function(sig) {
|
||||
|
Loading…
Reference in New Issue
Block a user