8000 bug #36334 [MonologBridge] Fix $level type (Seldaek) · symfony/symfony@ba52c62 · GitHub
[go: up one dir, main page]

Skip to content

Commit ba52c62

Browse files
committed
bug #36334 [MonologBridge] Fix $level type (Seldaek)
This PR was merged into the 5.1-dev branch. Discussion ---------- [MonologBridge] Fix $level type | Q | A | ------------- | --- | Branch? | master | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | | License | MIT Monolog accepts both level names like 'info' or int constants. The parent constructor will normalize it to an int. https://github.com/Seldaek/monolog/blob/master/src/Monolog/Handler/AbstractHandler.php#L53 Note that this may need to be applied on more handlers here I did not check, if someone feels like going over them all please feel free. Commits ------- c2a1781 Fix $level type
2 parents 0bec08f + c2a1781 commit ba52c62

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Symfony/Bridge/Monolog/Handler/MailerHandler.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,9 @@ class MailerHandler extends AbstractProcessingHandler
3030

3131
/**
3232
* @param callable|Email $messageTemplate
33+
* @param string|int $level The minimum logging level at which this handler will be triggered
3334
*/
34-
public function __construct(MailerInterface $mailer, $messageTemplate, int $level = Logger::DEBUG, bool $bubble = true)
35+
public function __construct(MailerInterface $mailer, $messageTemplate, $level = Logger::DEBUG, bool $bubble = true)
3536
{
3637
parent::__construct($level, $bubble);
3738

0 commit comments

Comments
 (0)
0