remove last remnants of treating a mailbox named "Sent" specially, in favor of special-use mailbox flags

a few places still looked at the name "Sent". but since we have special-use
flags, we should always look at those. this also changes the config so admins
can specify different names for the special-use mailboxes to create for new
accounts, e.g. in a different language. the old config option is still
understood, just deprecated.
This commit is contained in:
Mechiel Lukkien
2023-08-09 09:31:23 +02:00
parent 19b819d222
commit 34ede1075d
12 changed files with 176 additions and 52 deletions

View File

@ -77,7 +77,7 @@ func TestMailbox(t *testing.T) {
tcheck(t, err, "sent mailbox")
msent.MailboxID = mbsent.ID
msent.MailboxOrigID = mbsent.ID
err = acc.DeliverMessage(xlog, tx, &msent, msgFile, false, true, true, false)
err = acc.DeliverMessage(xlog, tx, &msent, msgFile, false, true, false)
tcheck(t, err, "deliver message")
err = tx.Get(&mbsent)
@ -90,7 +90,7 @@ func TestMailbox(t *testing.T) {
tcheck(t, err, "insert rejects mailbox")
mreject.MailboxID = mbrejects.ID
mreject.MailboxOrigID = mbrejects.ID
err = acc.DeliverMessage(xlog, tx, &mreject, msgFile, false, false, true, false)
err = acc.DeliverMessage(xlog, tx, &mreject, msgFile, false, true, false)
tcheck(t, err, "deliver message")
err = tx.Get(&mbrejects)