Code

Updated preg_match
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 11 May 2007 12:17:22 +0000 (12:17 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 11 May 2007 12:17:22 +0000 (12:17 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@6361 594d385d-05f5-0310-b6e9-bd551577e9d8

include/class_log.inc

index 032254bb81dc7c11692dfccf19d9f5d01c28d5a8..23f6f01282db4e0ca7e21e57c683c6d6c8bc4022 100644 (file)
@@ -63,13 +63,10 @@ class log {
     $entry['changes'] = $changes;
     $entry['result'] = $result;
  
-  
-
-
-    if(isset($this->config->current['LOGGING']) && preg_match("/syslog/i",$this->config->current['LOGGING'])){
+    if(isset($this->config->current['LOGGING']) && preg_match("/(^|,)syslog(,|$)/i",$this->config->current['LOGGING'])){
       @log::log_into_syslog($entry);
     }
-    if(isset($this->config->current['LOGGING']) && preg_match("/mysql/i",$this->config->current['LOGGING'])){
+    if(isset($this->config->current['LOGGING']) && preg_match("/(^|,)mysql(,|$)/i",$this->config->current['LOGGING'])){
       @log::log_into_db($entry);
     }
   }