Add name to DirectoryInfo messages

This commit is contained in:
Drew DeVault 2019-01-13 19:37:06 -05:00
parent 2750f99a60
commit 4b350dddea
2 changed files with 4 additions and 2 deletions

View file

@ -163,8 +163,9 @@ func (w *IMAPWorker) handleImapUpdate(update client.Update) {
case *client.MailboxUpdate: case *client.MailboxUpdate:
status := update.Mailbox status := update.Mailbox
w.worker.PostMessage(&types.DirectoryInfo{ w.worker.PostMessage(&types.DirectoryInfo{
ReadOnly: status.ReadOnly,
Flags: status.Flags, Flags: status.Flags,
Name: status.Name,
ReadOnly: status.ReadOnly,
Exists: int(status.Messages), Exists: int(status.Messages),
Recent: int(status.Recent), Recent: int(status.Recent),

View file

@ -83,8 +83,9 @@ type Directory struct {
type DirectoryInfo struct { type DirectoryInfo struct {
Message Message
ReadOnly bool
Flags []string Flags []string
Name string
ReadOnly bool
Exists, Recent, Unseen int Exists, Recent, Unseen int
} }