From 286b6ebbc738e24c10d80759a267c4dc0ff26f5a Mon Sep 17 00:00:00 2001 From: Krzysztof Sucherek Date: Thu, 5 Dec 2024 08:40:31 +0100 Subject: [PATCH] Revert types in logger signature. --- src/Ouzo/Core/Logger/LoggerAdapter.php | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/Ouzo/Core/Logger/LoggerAdapter.php b/src/Ouzo/Core/Logger/LoggerAdapter.php index 8db1651b..7635d50c 100644 --- a/src/Ouzo/Core/Logger/LoggerAdapter.php +++ b/src/Ouzo/Core/Logger/LoggerAdapter.php @@ -33,49 +33,49 @@ public function __construct( $this->minimalLevels = Arrays::getValue($loggerConfiguration, 'minimal_levels', []); } - public function emergency($message, array $context = []): void + public function emergency(string $message, array $context = []): void { $this->log(LogLevel::EMERGENCY, $message, $context); } - public function alert($message, array $context = []): void + public function alert(string $message, array $context = []): void { $this->log(LogLevel::ALERT, $message, $context); } - public function critical($message, array $context = []): void + public function critical(string $message, array $context = []): void { $this->log(LogLevel::CRITICAL, $message, $context); } - public function error($message, array $context = []): void + public function error(string $message, array $context = []): void { $this->log(LogLevel::ERROR, $message, $context); } - public function warning($message, array $context = []): void + public function warning(string $message, array $context = []): void { $this->log(LogLevel::WARNING, $message, $context); } - public function notice($message, array $context = []): void + public function notice(string $message, array $context = []): void { $this->log(LogLevel::NOTICE, $message, $context); } - public function info($message, array $context = []): void + public function info(string $message, array $context = []): void { $this->log(LogLevel::INFO, $message, $context); } - public function debug($message, array $context = []): void + public function debug(string $message, array $context = []): void { if ($this->isDebug()) { $this->log(LogLevel::DEBUG, $message, $context); } } - public function log($level, $message, array $context = []): void + public function log(string $level, $message, array $context = []): void { $ouzoLevel = LogLevelTranslator::toSyslogLevel($level); $minimalLevel = $this->minimalLevels ? Arrays::getValue($this->minimalLevels, $this->name, LOG_DEBUG) : LOG_DEBUG;