Other: Handle Seen/Flagged IMAP flags when APPENDing a message

When an IMAP client appends a message to a mailbox, it can specify
which flags it wants the appended message to have. We need to handle
these in a proton-specific way; not-seen messages need to be imported
with the Unread bool set to true, and flagged messages need to
additionally be imported with the Starred label.
This commit is contained in:
James Houlahan
2022-10-19 08:00:45 +02:00
parent a7a7d9a3d4
commit 04b6571cb8
12 changed files with 259 additions and 39 deletions

View File

@ -234,7 +234,7 @@ func buildPGPRFC822(kr *crypto.KeyRing, msg liteapi.Message, opts JobOptions) ([
hdr := getMessageHeader(msg, opts)
sigs, err := msg.ExtractSignatures(kr)
sigs, err := liteapi.ExtractSignatures(kr, msg.Body)
if err != nil {
log.WithError(err).WithField("id", msg.ID).Warn("Extract signature failed")
}