X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=inc%2Fmodule-functions.php;h=21c7a8116c0b9d0602e08dfb50b2c6100cc72b47;hb=5ab0d021f3e96722af5d96d2b9036430200c06cb;hp=9fdd7d36ff8ae6b5d269b165be88557a408376e8;hpb=b3db3a0ef875532db39f2365b52be8a576f0b796;p=mailer.git diff --git a/inc/module-functions.php b/inc/module-functions.php index 9fdd7d36ff..21c7a8116c 100644 --- a/inc/module-functions.php +++ b/inc/module-functions.php @@ -116,7 +116,7 @@ function getModuleStatus ($module) { // Is the module_status entry there? if (!isModuleStatusSet($module)) { // Abort - reportBug('Module status not set. module=' . $module); + reportBug(__FUNCTION__, __LINE__, 'Module status not set. module=' . $module); } // END - if // Return it @@ -288,7 +288,7 @@ function checkModulePermissions ($module = '') { // Data is missing so we add it if (isExtensionInstalledAndNewer('sql_patches', '0.3.6')) { /* - * Since 0.3.6 we have a has_menu column, this took me a half + * Since 0.3.6 there is a has_menu column, this took me a half * hour to find a loop here... *sigh* */ SQL_QUERY_ESC("INSERT INTO `{?_MYSQL_PREFIX?}_mod_reg` @@ -388,9 +388,9 @@ function ifModuleHasMenu ($module, $forceDb = FALSE) { } elseif (!isExtensionInstalled('sql_patches')) { // No ext-sql_patches installed, so maybe in admin/guest/member/sponsor area or no admin registered? $ret = in_array($module, array('admin', 'index', 'login', 'sponsor')); // Then there is a menu! - } else { - // Unsupported state! - logDebugMessage(__FUNCTION__, __LINE__, 'This should never be reached.'); + } elseif (!isInstallationPhase()) { + // Unsupported state, but ignored in installation phase + logDebugMessage(__FUNCTION__, __LINE__, 'This should never be reached, module[' . gettype($module) . ']=' . $module . ',forceDb=' . intval($forceDb)); } // Return status @@ -421,7 +421,7 @@ function loadModule () { $isModuleValid = FALSE; // Construct module name - $GLOBALS['module_inc'] = sprintf("inc/modules/%s.php", getModule()); + $GLOBALS['module_inc'] = sprintf("inc/modules/%s.php", getModule()); // Check module permission (again) $moduleState = checkModulePermissions();