X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodules%2Fadmin%2Fwhat-extensions.php;h=453e9c6142aadc305a9a865006f27e9afdeec4ae;hb=b50d521ee7818a82eb2fb38f17cc6f2675747971;hp=b346d479b1a77efb3cbf115e204f17609e2eb151;hpb=2df8c1757b41f35e7c5b6a92c52ca96ab1b0bcb8;p=mailer.git diff --git a/inc/modules/admin/what-extensions.php b/inc/modules/admin/what-extensions.php index b346d479b1..453e9c6142 100644 --- a/inc/modules/admin/what-extensions.php +++ b/inc/modules/admin/what-extensions.php @@ -332,7 +332,7 @@ ORDER BY break; case 'register': // Register new extension - // Do we have some tasks? + // Are there some tasks? $numTasks = countSumTotalData(getCurrentAdminId(), 'task_system', 'id', 'assigned_admin', true, "AND `task_type`='EXTENSION'"); // Is the id number valid and the task was found? @@ -362,10 +362,13 @@ ORDER BY // @TODO Rewrite this to a filter if (isExtensionActive('cache')) { // Remove cache file (will be auto-created again!) - if ($GLOBALS['cache_instance']->loadCacheFile('config')) $GLOBALS['cache_instance']->removeCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile('extension')) $GLOBALS['cache_instance']->removeCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile('filter')) $GLOBALS['cache_instance']->removeCacheFile(); - if ($GLOBALS['cache_instance']->loadCacheFile('modules')) $GLOBALS['cache_instance']->removeCacheFile(); + foreach (array('config', 'extension', 'filter', 'modules') as $cache) { + // Is the cache file there? + if ($GLOBALS['cache_instance']->loadCacheFile($cache)) { + // Remove cache file + $GLOBALS['cache_instance']->removeCacheFile(); + } // END - if + } // END - foreach } // END - if // Errors?