From 8c2814df89eb39d35b2b4d70b2b21bfe64a2b991 Mon Sep 17 00:00:00 2001 From: Mechiel Lukkien Date: Sat, 23 Sep 2023 14:50:02 +0200 Subject: [PATCH] imapserver: fix returning special-use mailbox "\Drafts" instead of "\Draft" related to issue #66 by x8x, though this doesn't fix that (macos mail doesn't yet request the special-use flags). --- imapserver/list.go | 2 +- imapserver/list_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/imapserver/list.go b/imapserver/list.go index 10f06a8..ed8ffa2 100644 --- a/imapserver/list.go +++ b/imapserver/list.go @@ -194,7 +194,7 @@ func (c *conn) cmdList(tag, cmd string, p *parser) { flags = append(flags, bare(`\Archive`)) } if info.mailbox.Draft { - flags = append(flags, bare(`\Draft`)) + flags = append(flags, bare(`\Drafts`)) } if info.mailbox.Junk { flags = append(flags, bare(`\Junk`)) diff --git a/imapserver/list_test.go b/imapserver/list_test.go index 62a067d..49d81a8 100644 --- a/imapserver/list_test.go +++ b/imapserver/list_test.go @@ -109,7 +109,7 @@ func TestListExtended(t *testing.T) { Fhasnochildren = `\HasNoChildren` Fnonexistent = `\NonExistent` Farchive = `\Archive` - Fdraft = `\Draft` + Fdraft = `\Drafts` Fjunk = `\Junk` Fsent = `\Sent` Ftrash = `\Trash`