Skip to content
Snippets Groups Projects
Commit e03d9e3a authored by Andreas Fischer's avatar Andreas Fischer
Browse files

Port log level filtering from OC_Log_Owncloud to OC_Log_Syslog.

parent 3534c3b3
No related branches found
No related tags found
No related merge requests found
......@@ -31,7 +31,10 @@ class OC_Log_Syslog {
* @param int level
*/
public static function write($app, $message, $level) {
$minLevel = min(OC_Config::getValue("loglevel", OC_Log::WARN), OC_Log::ERROR);
if ($level >= $minLevel) {
$syslog_level = self::$levels[$level];
syslog($syslog_level, '{'.$app.'} '.$message);
}
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment