From 5e59f0f3acb5645439eb8ca5f8030b17931f1102 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Sat, 31 Oct 2009 15:56:52 +0000 Subject: [PATCH] Parameter abortOnMiss renamed to strict, fixes for to strict getModule() call in logDebugMessage() --- inc/functions.php | 2 +- inc/wrapper-functions.php | 20 ++++++++++---------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/inc/functions.php b/inc/functions.php index 020ceb819a..6cb2c7e564 100644 --- a/inc/functions.php +++ b/inc/functions.php @@ -2972,7 +2972,7 @@ function logDebugMessage ($funcFile, $line, $message, $force=true) { // Log this message away, we better don't call app_die() here to prevent an endless loop $fp = fopen(getConfig('CACHE_PATH') . 'debug.log', 'a') or die(__FUNCTION__.'['.__LINE__.']: Cannot write logfile debug.log!'); - fwrite($fp, date('d.m.Y|H:i:s', time()) . '|' . getModule() . '|' . basename($funcFile) . '|' . $line . '|' . $message . "\n"); + fwrite($fp, date('d.m.Y|H:i:s', time()) . '|' . getModule(false) . '|' . basename($funcFile) . '|' . $line . '|' . $message . "\n"); fclose($fp); } // END - if } diff --git a/inc/wrapper-functions.php b/inc/wrapper-functions.php index c7711857d6..f8b068dc35 100644 --- a/inc/wrapper-functions.php +++ b/inc/wrapper-functions.php @@ -488,12 +488,12 @@ function setWhatFromConfig ($configEntry) { } // Checks wether what is set and optionally aborts on miss -function isWhatSet ($abortOnMiss = false) { +function isWhatSet ($strict = false) { // Check for it $isset = (isset($GLOBALS['what'])); // Should we abort here? - if (($abortOnMiss === true) && ($isset === false)) { + if (($strict === true) && ($isset === false)) { // Output backtrace debug_report_bug('what is empty.'); } // END - if @@ -523,12 +523,12 @@ function setAction ($newAction) { } // Checks wether action is set and optionally aborts on miss -function isActionSet ($abortOnMiss = false) { +function isActionSet ($strict = false) { // Check for it $isset = (isset($GLOBALS['action'])); // Should we abort here? - if (($abortOnMiss === true) && ($isset === false)) { + if (($strict === true) && ($isset === false)) { // Output backtrace debug_report_bug('action is empty.'); } // END - if @@ -538,12 +538,12 @@ function isActionSet ($abortOnMiss = false) { } // Getter for 'module' value -function getModule () { +function getModule ($strict = true) { // Default is null $module = null; // Is the value set? - if (isModuleSet(true)) { + if (isModuleSet($strict)) { // Then use it $module = $GLOBALS['module']; } // END - if @@ -559,12 +559,12 @@ function setModule ($newModule) { } // Checks wether module is set and optionally aborts on miss -function isModuleSet ($abortOnMiss = false) { +function isModuleSet ($strict = false) { // Check for it $isset = (!empty($GLOBALS['module'])); // Should we abort here? - if (($abortOnMiss === true) && ($isset === false)) { + if (($strict === true) && ($isset === false)) { // Output backtrace print 'Module not set!
';
 		debug_print_backtrace();
@@ -597,12 +597,12 @@ function setOutputMode ($newOutputMode) {
 }
 
 // Checks wether output_mode is set and optionally aborts on miss
-function isOutputModeSet ($abortOnMiss =  false) {
+function isOutputModeSet ($strict =  false) {
 	// Check for it
 	$isset = (isset($GLOBALS['output_mode']));
 
 	// Should we abort here?
-	if (($abortOnMiss === true) && ($isset === false)) {
+	if (($strict === true) && ($isset === false)) {
 		// Output backtrace
 		debug_report_bug('output_mode is empty.');
 	} // END - if
-- 
2.39.5