mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Invert default log configuration.
Windows only has 4 log levels instead of 8. This causes notice errors when trying to use 'alert' and a few other levels. Fixes #3055
This commit is contained in:
parent
ab6fab6675
commit
a27e171f0f
1 changed files with 10 additions and 10 deletions
|
@ -88,14 +88,14 @@ class CakeLog {
|
|||
* @var array
|
||||
*/
|
||||
protected static $_defaultLevels = array(
|
||||
LOG_EMERG => 'emergency',
|
||||
LOG_ALERT => 'alert',
|
||||
LOG_CRIT => 'critical',
|
||||
LOG_ERR => 'error',
|
||||
LOG_WARNING => 'warning',
|
||||
LOG_NOTICE => 'notice',
|
||||
LOG_INFO => 'info',
|
||||
LOG_DEBUG => 'debug',
|
||||
'emergency' => LOG_EMERG,
|
||||
'alert' => LOG_ALERT,
|
||||
'critical' => LOG_CRIT,
|
||||
'error' => LOG_ERR,
|
||||
'warning' => LOG_WARNING,
|
||||
'notice' => LOG_NOTICE,
|
||||
'info' => LOG_INFO,
|
||||
'debug' => LOG_DEBUG,
|
||||
);
|
||||
|
||||
/**
|
||||
|
@ -276,8 +276,8 @@ class CakeLog {
|
|||
* @return array default log levels
|
||||
*/
|
||||
public static function defaultLevels() {
|
||||
self::$_levels = self::$_defaultLevels;
|
||||
self::$_levelMap = array_flip(self::$_levels);
|
||||
self::$_levelMap = self::$_defaultLevels;
|
||||
self::$_levels = array_flip(self::$_levelMap);
|
||||
return self::$_levels;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue