Update the comment in encrypted message branch

Since try_decrypt does not check if the message has valid signatures
anymore, it may return empty signatures set, which means the message is
not a valid autocrypt message.
This commit is contained in:
Alexander Krotov
2020-08-02 16:14:30 +03:00
committed by link2xt
parent ac232a5dbf
commit a4ca9f738b

View File

@@ -131,7 +131,10 @@ impl MimeMessage {
let (mail, signatures) = match e2ee::try_decrypt(context, &mail, message_time).await {
Ok((raw, signatures)) => {
if let Some(raw) = raw {
// Valid autocrypt message, encrypted
// Encrypted, but maybe unsigned message. Only if
// `signatures` set is non-empty, it is a valid
// autocrypt message.
mail_raw = raw;
let decrypted_mail = mailparse::parse_mail(&mail_raw)?;
if std::env::var(crate::DCC_MIME_DEBUG).is_ok() {