X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmysql-manager.php;h=b9eee9d47739ac896f5b38d720afcc0e3e26549a;hb=5b19f243da1b69e64dc8c704a7dfa473473a9023;hp=7137be73f1506e172de78d16de92b78503ed3168;hpb=98077af43126dd7c274fe57f6ea0494e906e8943;p=mailer.git diff --git a/inc/mysql-manager.php b/inc/mysql-manager.php index 7137be73f1..b9eee9d477 100644 --- a/inc/mysql-manager.php +++ b/inc/mysql-manager.php @@ -208,16 +208,16 @@ function checkModulePermissions ($mod) { } else { // @TODO Nothing helped??? DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("ret=%s,locked=%s,admin=%s,mem=%s", - $ret, - $locked, - $admin, - $mem + $ret, + $locked, + $admin, + $mem )); } } // END - if // Still no luck or not found? - if (($ret == 'cache_miss') || ($found === false)) { + if (($found === false) && (!EXT_IS_ACTIVE('cache')) && ($ret != 'done')) { // ----- Legacy module ----- ---- Module in base folder ---- --- Module with extension's name --- if ((isFileReadable(sprintf("%sinc/modules/%s.php", constant('PATH'), $mod))) || (isFileReadable(sprintf("%s%s.php", constant('PATH'), $mod))) || (isFileReadable(sprintf("%s%s/%s.php", constant('PATH'), $extension, $mod)))) { // Data is missing so we add it @@ -250,7 +250,10 @@ function checkModulePermissions ($mod) { // Module not found we don't add it to the database $ret = '404'; } - } elseif (!$found) { + } elseif ($ret == 'cache_miss') { + // Rebuild the cache files + rebuildCacheFiles('modreg', 'modreg'); + } elseif ($found === false) { // Problem with module detected DEBUG_LOG(__FUNCTION__, __LINE__, sprintf("Problem in module %s detected. ret=%s, locked=%s, hidden=%s, mem=%s, admin=%s", $mod,