]> git.mxchange.org Git - mailer.git/blobdiff - inc/wrapper-functions.php
Missing function added (but will be removed once the EL branch is ready)
[mailer.git] / inc / wrapper-functions.php
index 2127a208e7e62d1e6b70ade8346aa97d1f12fdd9..6e8cb2e97b73f771c1c6fe6ef535a81d11b53984 100644 (file)
@@ -563,12 +563,12 @@ function isWhatSet ($strict =  false) {
 }
 
 // Getter for 'action' value
-function getAction () {
+function getAction ($strict = true) {
        // Default is null
        $action = null;
 
        // Is the value set?
-       if (isActionSet(true)) {
+       if (isActionSet(($strict) && (getOutputMode() == 0))) {
                // Then use it
                $action = $GLOBALS['action'];
        } // END - if
@@ -716,7 +716,10 @@ function isExtensionInstalledAndNewer ($ext_name, $version) {
        // Is an cache entry found?
        if (!isset($GLOBALS['ext_installed_newer'][$ext_name][$version])) {
                $GLOBALS['ext_installed_newer'][$ext_name][$version] = ((isExtensionInstalled($ext_name)) && (getExtensionVersion($ext_name) >= $version));
-       } // END - if
+       } else {
+               // Cache hits should be incremented twice
+               incrementStatsEntry('cache_hits', 2);
+       }
 
        // Return it
        //* DEBUG: */ print __FUNCTION__.':'.$ext_name.'=&gt;'.$version.':'.intval($GLOBALS['ext_installed_newer'][$ext_name][$version]).'<br />';
@@ -728,7 +731,10 @@ function isExtensionInstalledAndOlder ($ext_name, $version) {
        // Is an cache entry found?
        if (!isset($GLOBALS['ext_installed_older'][$ext_name][$version])) {
                $GLOBALS['ext_installed_older'][$ext_name][$version] = ((isExtensionInstalled($ext_name)) && (isExtensionOlder($ext_name, $version)));
-       } // END - if
+       } else {
+               // Cache hits should be incremented twice
+               incrementStatsEntry('cache_hits', 2);
+       }
 
        // Return it
        //* DEBUG: */ print __FUNCTION__.':'.$ext_name.'&lt;'.$version.':'.intval($GLOBALS['ext_installed_older'][$ext_name][$version]).'<br />';
@@ -935,5 +941,10 @@ function ifFatalErrorsDetected () {
        return (getTotalFatalErrors() > 0);
 }
 
+// Wrapper until we merged to the EL branch
+function preCompileCode ($code, $template = '', $compiled = false, $full = true, $overwrite = false) {
+       return compileCode($code, false, true, $full);
+}
+
 // [EOF]
 ?>