Mark sent messages as "seen" in maildir

- Add maildir flags to complement a messages imap flags
- Set the "seen" flag on sent messages when using the maildir backend
- Cleanup AppendMessage interface to use models.Flag for both IMAP and
  maildir
This commit is contained in:
Galen Abell 2020-03-03 08:45:06 -05:00 committed by Reto Brunner
commit 6ff3c7a1ba
10 changed files with 65 additions and 21 deletions
worker/imap

View file

@ -28,7 +28,7 @@ func (m appendLiteral) Len() int {
}
func (imapw *IMAPWorker) handleAppendMessage(msg *types.AppendMessage) {
if err := imapw.client.Append(msg.Destination, msg.Flags, msg.Date,
if err := imapw.client.Append(msg.Destination, translateFlags(msg.Flags), msg.Date,
&appendLiteral{
Reader: msg.Reader,
Length: msg.Length,