mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-07 08:27:03 +03:00
There's no VersionsCache
This commit is contained in:
parent
abe2af153d
commit
9ba11c77eb
1 changed files with 3 additions and 11 deletions
|
|
@ -214,7 +214,6 @@ trait User
|
||||||
|
|
||||||
$bMainCache = false;
|
$bMainCache = false;
|
||||||
$bFilesCache = false;
|
$bFilesCache = false;
|
||||||
$bVersionsCache = false;
|
|
||||||
|
|
||||||
$iOneDay1 = 60 * 60 * 23;
|
$iOneDay1 = 60 * 60 * 23;
|
||||||
$iOneDay2 = 60 * 60 * 25;
|
$iOneDay2 = 60 * 60 * 25;
|
||||||
|
|
@ -227,7 +226,6 @@ trait User
|
||||||
|
|
||||||
$iMainCacheTime = !empty($aTimers[0]) && \is_numeric($aTimers[0]) ? (int) $aTimers[0] : 0;
|
$iMainCacheTime = !empty($aTimers[0]) && \is_numeric($aTimers[0]) ? (int) $aTimers[0] : 0;
|
||||||
$iFilesCacheTime = !empty($aTimers[1]) && \is_numeric($aTimers[1]) ? (int) $aTimers[1] : 0;
|
$iFilesCacheTime = !empty($aTimers[1]) && \is_numeric($aTimers[1]) ? (int) $aTimers[1] : 0;
|
||||||
$iVersionsCacheTime = !empty($aTimers[2]) && \is_numeric($aTimers[2]) ? (int) $aTimers[2] : 0;
|
|
||||||
|
|
||||||
if (0 === $iMainCacheTime || $iMainCacheTime + $iOneDay1 < \time())
|
if (0 === $iMainCacheTime || $iMainCacheTime + $iOneDay1 < \time())
|
||||||
{
|
{
|
||||||
|
|
@ -241,19 +239,13 @@ trait User
|
||||||
$iFilesCacheTime = \time();
|
$iFilesCacheTime = \time();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (0 === $iVersionsCacheTime || $iVersionsCacheTime + $iOneDay3 < \time())
|
if ($bMainCache || $bFilesCache)
|
||||||
{
|
|
||||||
$bVersionsCache = true;
|
|
||||||
$iVersionsCacheTime = \time();
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($bMainCache || $bFilesCache || $bVersionsCache)
|
|
||||||
{
|
{
|
||||||
if (!$this->StorageProvider()->Put(null,
|
if (!$this->StorageProvider()->Put(null,
|
||||||
\RainLoop\Providers\Storage\Enumerations\StorageType::NOBODY, 'Cache/Timers',
|
\RainLoop\Providers\Storage\Enumerations\StorageType::NOBODY, 'Cache/Timers',
|
||||||
\implode(',', array($iMainCacheTime, $iFilesCacheTime, $iVersionsCacheTime))))
|
\implode(',', array($iMainCacheTime, $iFilesCacheTime))))
|
||||||
{
|
{
|
||||||
$bMainCache = $bFilesCache = $bVersionsCache = false;
|
$bMainCache = $bFilesCache = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue