Skip to content
Snippets Groups Projects
Commit 6c1dc2ef authored by Prasad's avatar Prasad
Browse files

Turn on log4php.debug only when required

parent 448db89e
No related branches found
No related tags found
No related merge requests found
......@@ -22,10 +22,16 @@ require_once('config.php');
// Performance Optimization: Configure the log folder
@include_once('config.performance.php');
global $PERFORMANCE_CONFIG;
if(isset($PERFORMANCE_CONFIG) && isset($PERFORMANCE_CONFIG['LOG4PHP_DEBUG']) && $PERFORMANCE_CONFIG['LOG4PHP_DEBUG']) {
define('LOG4PHP_DIR', 'libraries/log4php.debug');
} else {
define('LOG4PHP_DIR', 'libraries/log4php');
}
// END
define('LOG4PHP_DEFAULT_INIT_OVERRIDE', true);
define('LOG4PHP_DIR', 'libraries/log4php.debug');
  • Contributor

    @prasad here on line 33 you define LOG4PHP_DIR again, overriding whatever the above if-else condition does.

  • Please register or sign in to reply
require_once(LOG4PHP_DIR.'/Logger.php');
Logger::configure('log4php.properties');
?>
\ No newline at end of file
?>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment