Undeleted count cache fixes

This commit is contained in:
RainLoop Team 2014-09-29 21:20:13 +04:00
parent a1cde2c246
commit 9dbed6f929

View file

@ -670,6 +670,12 @@ class MailClient
if (\MailSo\Config::$MessageListUndeletedFilter)
{
$oFolder = $this->oImapClient->FolderCurrentInformation();
if (!$oFolder || $oFolder->FolderName !== $sFolderName)
{
$this->oImapClient->FolderExamine($sFolderName);
}
$aUids = $this->getSearchUidsResult('',
$sFolderName, false, false, false, $oCacher);
@ -683,7 +689,7 @@ class MailClient
$iUnseenCount = \count($aUids);
}
else
else if (0 === $iNewCount)
{
$iCount = 0;
$iUnseenCount = 0;