Bläddra i källkod

Ticket #4284 - Timeline: Don't cache empty items.

AntonLV 3 år sedan
förälder
incheckning
abd51b2773
1 ändrade filer med 1 tillägg och 1 borttagningar
  1. 1 1
      modules/boonex/timeline/classes/BxTimelineTemplate.php

+ 1 - 1
modules/boonex/timeline/classes/BxTimelineTemplate.php

@@ -1547,7 +1547,7 @@ class BxTimelineTemplate extends BxBaseModNotificationsTemplate
 
 
         $aBrowseParams['dynamic_mode'] = true;
         $aBrowseParams['dynamic_mode'] = true;
         $aResult = $this->getData($aEvent, $aBrowseParams);
         $aResult = $this->getData($aEvent, $aBrowseParams);
-        if(!empty($aResult) && isset($aResult['_cache']) && (bool)$aResult['_cache'] === false)
+        if(empty($aResult) || (isset($aResult['_cache']) && (bool)$aResult['_cache'] === false))
             return $aResult;
             return $aResult;
 
 
         $oCache->setData($sCacheKey, serialize($aResult), $iCacheLifetime);           
         $oCache->setData($sCacheKey, serialize($aResult), $iCacheLifetime);