Code

Migrated class_log
authorcajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 24 Jul 2008 11:52:41 +0000 (11:52 +0000)
committercajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 24 Jul 2008 11:52:41 +0000 (11:52 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@12013 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-core/include/class_log.inc

index fa4482e6b3b97ad794f8abde63e86ee546fb8179..24a64258027c895eb175f5e8dd7e36c82c53b6e0 100644 (file)
@@ -76,7 +76,7 @@ class log {
     $entry['changes']   = $changes;
     $entry['result']    = $result;
 
-    if(!isset($this->config->current['LOGGING']) && empty($entry['user'])){
+    if($this->config->get_cfg_value("logging") == ""  && empty($entry['user'])){
       $entry['user']  = "unknown";
     }
  
@@ -90,15 +90,15 @@ class log {
       
     }else{
 
-      if(!isset($this->config->current['LOGGING'])){
+      if ($this->conifg->get_cfg_value("logging") == ""){
         $this->log_into_syslog($entry);
       }else{
 
         /* Start logging for configured methods */
-        if(isset($this->config->current['LOGGING']) && preg_match("/(^|,)syslog(,|$)/i",$this->config->current['LOGGING'])){
+        if(preg_match("/(^|,)syslog(,|$)/i",$this->config->get_cfg_value("logging"))){
           $this->log_into_syslog($entry);
         }
-        if(isset($this->config->current['LOGGING']) && preg_match("/(^|,)mysql(,|$)/i",$this->config->current['LOGGING'])){
+        if(preg_match("/(^|,)mysql(,|$)/i",$this->config->get_cfg_value("logging"))){
           $this->log_into_db($entry);
         }
       }