Count recent messages in maildir exists total too
This commit is contained in:
parent
ae7595e945
commit
08eabef17d
1 changed files with 1 additions and 1 deletions
|
@ -136,7 +136,6 @@ func (w *Worker) getDirectoryInfo(name string) *models.DirectoryInfo {
|
|||
w.worker.Logger.Printf("could not get uids: %v", err)
|
||||
return dirInfo
|
||||
}
|
||||
dirInfo.Exists = len(uids)
|
||||
|
||||
recent, err := dir.UnseenCount()
|
||||
if err != nil {
|
||||
|
@ -166,6 +165,7 @@ func (w *Worker) getDirectoryInfo(name string) *models.DirectoryInfo {
|
|||
}
|
||||
}
|
||||
dirInfo.Unseen += dirInfo.Recent
|
||||
dirInfo.Exists = len(uids) + recent
|
||||
return dirInfo
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue