cron logging: really print messages of level >= LOG_WARNING

also fix mixed indentation
This commit is contained in:
Daniel Reichelt
2016-02-19 18:48:20 +01:00
parent e3a594f3e7
commit 3d2b672feb

View File

@@ -104,13 +104,14 @@ class FroxlorLogger {
return;
}
if (self::$crondebug_flag) {
if (self::$crondebug_flag
|| ($action == CRON_ACTION && $type <= LOG_WARNING)) {
echo "[".getLogLevelDesc($type)."] ".$text.PHP_EOL;
}
if (Settings::Get('logger.log_cron') == '0'
&& $action == CRON_ACTION
&& $type > LOG_WARNING // warnings, errors and critical mesages WILL be logged
&& $action == CRON_ACTION
&& $type > LOG_WARNING // warnings, errors and critical mesages WILL be logged
) {
return;
}