Several kinky code smoothed, fixes for admin login
[mailer.git] / inc / extensions-functions.php
index bed7a9c3ce66c1e0186c4284a981d8a6154ca9e4..dfa79d8fb9c739f19abcb241befba9d73297b13d 100644 (file)
@@ -102,7 +102,7 @@ function loadExtension ($ext_name, $ext_mode = 'init', $ext_ver = '', $dry_run =
                        // Download functions file
                        loadIncludeOnce($funcsInclude);
                } // END - if
-       } elseif ((!isset($GLOBALS['cache_array']['extension']['ext_func'][$ext_name])) && (isDebugModeEnabled()) && (getOutputMode() == '0') && ($ext_name != 'sql_patches') && (substr($ext_name, 0, 10) != 'admintheme') && (getExtensionMode() == 'test')) {
+       } elseif ((!isset($GLOBALS['cache_array']['extension']['ext_func'][$ext_name])) && (isDebugModeEnabled()) && (getOutputMode() == 0) && ($ext_name != 'sql_patches') && (substr($ext_name, 0, 10) != 'admintheme') && (getExtensionMode() == 'test')) {
                // No functions file is not so good...
                logDebugMessage(__FUNCTION__, __LINE__, sprintf("NOTICE: Extension %s has no own functions file or we cannot read from it. mode=%s",
                        $ext_name,
@@ -534,7 +534,7 @@ function getExtensionVersion ($ext_name) {
 
                // Count cache hits
                incrementStatsEntry('cache_hits');
-       } elseif ((!isCacheInstanceValid()) || (isset($GLOBALS['cache_array']['extension'])) || (getOutputMode() != '0')) {
+       } elseif ((!isCacheInstanceValid()) || (isset($GLOBALS['cache_array']['extension'])) || (getOutputMode() != 0)) {
                // Load from database
                $result = SQL_QUERY_ESC("SELECT `ext_version` FROM `{?_MYSQL_PREFIX?}_extensions` WHERE `ext_name`='%s' LIMIT 1",
                        array($ext_name), __FUNCTION__, __LINE__);
@@ -1036,7 +1036,7 @@ function addExtensionNotes ($ver) {
        $out = ''; $content = array();
 
        // Is do we have verbose output enabled?
-       if ((getConfig('verbose_sql') == 'Y') || (!isExtensionActive('sql_patches'))) {
+       if ((!isExtensionActive('sql_patches')) || (getConfig('verbose_sql') == 'Y')) {
                // Update notes found?
                if (getExtensionUpdateNotes($ver) != '') {
                        // Update notes found
@@ -1391,9 +1391,9 @@ function FILTER_INIT_EXTENSIONS () {
        // Do we have some entries?
        //* DEBUG */ print __FUNCTION__.': ENTRY!<br />';
        if (isset($GLOBALS['cache_array']['extension']['ext_name'])) {
-               //* DEBUG */ print __FUNCTION__.': CACHE - START!<br />';
                // Load all found extensions if found
-               foreach ($GLOBALS['cache_array']['extension']['ext_name'] as $key=>$ext_name) {
+               //* DEBUG */ print __FUNCTION__.': CACHE - START!<br />';
+               foreach ($GLOBALS['cache_array']['extension']['ext_name'] as $key => $ext_name) {
                        // Load it
                        //* DEBUG */ print __FUNCTION__.': '.$ext_name.' - START<br />';
                        loadExtension($ext_name, 'init');