From 75a55c3457a3d9db9bd865a624eeaaaf5204878f Mon Sep 17 00:00:00 2001 From: hickert Date: Thu, 5 Aug 2010 08:27:22 +0000 Subject: [PATCH] Updated stats class usage -Added stats::log to php_setup.inc: gosaRaiseError git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@19361 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-core/include/php_setup.inc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gosa-core/include/php_setup.inc b/gosa-core/include/php_setup.inc index 515830aa6..c1e7184a5 100644 --- a/gosa-core/include/php_setup.inc +++ b/gosa-core/include/php_setup.inc @@ -69,6 +69,12 @@ function gosaRaiseError($errno, $errstr, $errfile, $errline) new log("debug","all",$errfile,array(),"Type:".$errno.", Message:".$errstr.", File:".$errfile.", Line: ".$errline); } + // Log errors in usage DB + if(class_exists('stats') && !preg_match("/No such object/",$errstr)){ + stats::log('error', $class = 'ERROR', $category = array(), $action = __FUNCTION__, + $amount = 1, $duration = 0, $errno); + } + /* Create header as needed */ if ($error_collector == ""){ -- 2.30.2