Fix for DEFAULT_SALT_LENGTH
[mailer.git] / inc / filters.php
index 1d7a5004760d661695a464d82faa6a6a84cd918f..2aed78b9455016de30a73928b1ecb5d9347aa451 100644 (file)
@@ -442,9 +442,15 @@ function FILTER_COMPILE_CONFIG ($code) {
                                if (isConfigEntrySet($matches[1][$key])) {
                                        // Set it for caching
                                        $GLOBALS['compile_config'][$matches[1][$key]] = getConfig($matches[1][$key]);
-                               } else {
+                               } elseif (isConfigEntrySet('default_' . strtoupper($matches[1][$key]))) {
+                                       // Use default value
+                                       $GLOBALS['compile_config'][$matches[1][$key]] = getConfig('DEFAULT_' . strtoupper($matches[1][$key]));
+                               } elseif (isMessageIdValid('DEFAULT_' . strtoupper($matches[1][$key]))) {
                                        // No config, try the language system
                                        $GLOBALS['compile_config'][$matches[1][$key]] = getMessage('DEFAULT_' . strtoupper($matches[1][$key]));
+                               } else {
+                                       // Unhandled!
+                                       $GLOBALS['compile_config'][$matches[1][$key]] = '!' . $matches[1][$key] . '!';
                                }
                        } // END - if
 
@@ -580,6 +586,16 @@ function FILTER_HTML_INCLUDE_USERS ($mode) {
 
 // Filter for determining what/action/module
 function FILTER_DETERMINE_WHAT_ACTION () {
+       // In installation phase we don't have what/action
+       if (isInstallationPhase()) {
+               // Set both to empty
+               setAction('');
+               setWhat('');
+
+               // Abort here
+               return;
+       } // END - if
+
        // Get all values
        if ((getOutputMode() != 1) && (getOutputMode() != -1)) {
                // Fix module