Skip to content

Commit

Permalink
[HttpKernel] Update phpdoc
Browse files Browse the repository at this point in the history
  • Loading branch information
angelov committed Dec 22, 2022
1 parent 49bad8e commit e24c5ba
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/Symfony/Component/HttpKernel/Attribute/LogLevel.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,12 @@
#[\Attribute(\Attribute::TARGET_CLASS)]
final class LogLevel
{
/**
* @param \Psr\Log\LogLevel::* $level
*/
public function __construct(public readonly string $level)
{
if (!\defined(sprintf("\Psr\Log\LogLevel::%s", strtoupper($this->level)))) {
if (!\defined('Psr\Log\LogLevel::'.strtoupper($this->level))) {
throw new \InvalidArgumentException(sprintf('Invalid log level - "%s".', $this->level));
}
}
Expand Down

0 comments on commit e24c5ba

Please sign in to comment.