From 633ec3758910482863299c7122dda3c15d9758a8 Mon Sep 17 00:00:00 2001 From: admin Date: Fri, 15 Sep 2006 20:43:32 +0000 Subject: --- system/libraries/Log.php | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/system/libraries/Log.php b/system/libraries/Log.php index 6c78316f1..392742584 100644 --- a/system/libraries/Log.php +++ b/system/libraries/Log.php @@ -40,23 +40,25 @@ class CI_Log { * @param string the error threshold * @param string the date formatting codes */ - function CI_Log($path = '', $threshold = 4, $date_fmt = '') - { - $this->log_path = ($path != '') ? $path : BASEPATH.'logs/'; + function CI_Log() + { + $config =& _get_config(); + + $this->log_path = ($config['log_path'] != '') ? $config['log_path'] : BASEPATH.'logs/'; if ( ! is_dir($this->log_path) OR ! is_writable($this->log_path)) { $this->_enabled = FALSE; } - if (is_numeric($threshold)) + if (is_numeric($config['log_threshold'])) { - $this->_threshold = $threshold; + $this->_threshold = $config['log_threshold']; } - if ($date_fmt != '') + if ($config['log_date_format'] != '') { - $this->_date_fmt = $date_fmt; + $this->_date_fmt = $config['log_date_format']; } } // END CI_Log() -- cgit v1.2.3-24-g4f1b