From 948ef46290c535bdb320cdb5b1801bbcfd71047c Mon Sep 17 00:00:00 2001 From: Vladimir Plakhotnikov Date: Sat, 5 Oct 2024 00:49:37 +0300 Subject: [PATCH] Logger Handler: fix Alert and Emergency levels (#109) Signed-off-by: Plakhotnikov Vladimir --- src/Logger/Handler.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Logger/Handler.php b/src/Logger/Handler.php index c4cdd17..8d46811 100644 --- a/src/Logger/Handler.php +++ b/src/Logger/Handler.php @@ -50,8 +50,8 @@ protected function write(array|LogRecord $record): void /** @psalm-suppress DeprecatedConstant */ match ($level) { - Logger::ERROR, Logger::CRITICAL => $this->logger->error($message), - Logger::WARNING, Logger::ALERT, Logger::EMERGENCY => $this->logger->warning($message), + Logger::ERROR, Logger::CRITICAL, Logger::ALERT, Logger::EMERGENCY => $this->logger->error($message), + Logger::WARNING => $this->logger->warning($message), Logger::INFO, Logger::NOTICE => $this->logger->info($message), Logger::DEBUG => $this->logger->debug($message), };