From: Roland Häder Date: Fri, 6 Mar 2009 21:55:22 +0000 (+0000) Subject: Checking for 'cache' in it's own filters is obsolete->removed X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=edc4fd56d8e32cf1afe593a9a33b349228b5011e;p=mailer.git Checking for 'cache' in it's own filters is obsolete->removed --- diff --git a/inc/libs/cache_functions.php b/inc/libs/cache_functions.php index f8ff4882a0..30209debe8 100644 --- a/inc/libs/cache_functions.php +++ b/inc/libs/cache_functions.php @@ -413,16 +413,15 @@ class CacheSystem { function isCacheReadable () { return INCLUDE_READABLE($this->inc); } + } // END - class // Destroy the cache on extension changes function FILTER_CACHE_DESTROY_ON_EXT_CHANGE ($data) { // Remove cache - if (EXT_IS_ACTIVE("cache")) { - if ($GLOBALS['cache_instance']->loadCacheFile("config")) $GLOBALS['cache_instance']->destroyCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile("extensions")) $GLOBALS['cache_instance']->destroyCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile("modreg")) $GLOBALS['cache_instance']->destroyCacheFile(); - } // END - if + if ($GLOBALS['cache_instance']->loadCacheFile("config")) $GLOBALS['cache_instance']->destroyCacheFile(); + if ($GLOBALS['cache_instance']->loadCacheFile("extensions")) $GLOBALS['cache_instance']->destroyCacheFile(); + if ($GLOBALS['cache_instance']->loadCacheFile("modreg")) $GLOBALS['cache_instance']->destroyCacheFile(); // Return it return $data; @@ -431,25 +430,21 @@ function FILTER_CACHE_DESTROY_ON_EXT_CHANGE ($data) { // Destroy the cache on changing admin function FILTER_CACHE_DESTROY_ON_ADMIN_CHANGE () { // Remove cache - if (EXT_IS_ACTIVE("cache")) { - if ($GLOBALS['cache_instance']->loadCacheFile("admins")) $GLOBALS['cache_instance']->destroyCacheFile(); - } // END - if + if ($GLOBALS['cache_instance']->loadCacheFile("admins")) $GLOBALS['cache_instance']->destroyCacheFile(); } // Destroy all cache files function FILTER_CACHE_DESTROY_ALL () { - // Remove cache - if (EXT_IS_ACTIVE("cache")) { - if ($GLOBALS['cache_instance']->loadCacheFile("admins")) $GLOBALS['cache_instance']->destroyCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile("admins_acls")) $GLOBALS['cache_instance']->destroyCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile("config")) $GLOBALS['cache_instance']->destroyCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile("extensions")) $GLOBALS['cache_instance']->destroyCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile("modreg")) $GLOBALS['cache_instance']->destroyCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile("refdepths")) $GLOBALS['cache_instance']->destroyCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile("refsystem")) $GLOBALS['cache_instance']->destroyCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile("themes")) $GLOBALS['cache_instance']->destroyCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile("revision")) $GLOBALS['cache_instance']->destroyCacheFile(); - } // END - if + // Remove cache files + if ($GLOBALS['cache_instance']->loadCacheFile("admins")) $GLOBALS['cache_instance']->destroyCacheFile(); + if ($GLOBALS['cache_instance']->loadCacheFile("admins_acls")) $GLOBALS['cache_instance']->destroyCacheFile(); + if ($GLOBALS['cache_instance']->loadCacheFile("config")) $GLOBALS['cache_instance']->destroyCacheFile(); + if ($GLOBALS['cache_instance']->loadCacheFile("extensions")) $GLOBALS['cache_instance']->destroyCacheFile(); + if ($GLOBALS['cache_instance']->loadCacheFile("modreg")) $GLOBALS['cache_instance']->destroyCacheFile(); + if ($GLOBALS['cache_instance']->loadCacheFile("refdepths")) $GLOBALS['cache_instance']->destroyCacheFile(); + if ($GLOBALS['cache_instance']->loadCacheFile("refsystem")) $GLOBALS['cache_instance']->destroyCacheFile(); + if ($GLOBALS['cache_instance']->loadCacheFile("themes")) $GLOBALS['cache_instance']->destroyCacheFile(); + if ($GLOBALS['cache_instance']->loadCacheFile("revision")) $GLOBALS['cache_instance']->destroyCacheFile(); } // Filter for purging entire admin menu cache