Remove leftover outbox handling
This commit is contained in:
parent
fa102822bb
commit
18ad982c53
|
@ -110,7 +110,7 @@ func newIMAPBaseRenderData(ctx *alps.Context,
|
||||||
}
|
}
|
||||||
|
|
||||||
var mailboxes []MailboxInfo
|
var mailboxes []MailboxInfo
|
||||||
var active, inbox, outbox *MailboxStatus
|
var active, inbox *MailboxStatus
|
||||||
err = ctx.Session.DoIMAP(func(c *imapclient.Client) error {
|
err = ctx.Session.DoIMAP(func(c *imapclient.Client) error {
|
||||||
var err error
|
var err error
|
||||||
if mailboxes, err = listMailboxes(c); err != nil {
|
if mailboxes, err = listMailboxes(c); err != nil {
|
||||||
|
@ -155,10 +155,6 @@ func newIMAPBaseRenderData(ctx *alps.Context,
|
||||||
mailboxes[i].Unseen = int(inbox.Unseen)
|
mailboxes[i].Unseen = int(inbox.Unseen)
|
||||||
mailboxes[i].Total = int(inbox.Messages)
|
mailboxes[i].Total = int(inbox.Messages)
|
||||||
}
|
}
|
||||||
if outbox != nil && mailboxes[i].Name == outbox.Name {
|
|
||||||
mailboxes[i].Unseen = int(outbox.Unseen)
|
|
||||||
mailboxes[i].Total = int(outbox.Messages)
|
|
||||||
}
|
|
||||||
|
|
||||||
if ptr, ok := mmap[mailboxes[i].Name]; ok {
|
if ptr, ok := mmap[mailboxes[i].Name]; ok {
|
||||||
*ptr = &mailboxes[i]
|
*ptr = &mailboxes[i]
|
||||||
|
|
Loading…
Reference in a new issue