mirror of
https://github.com/Seldaek/monolog.git
synced 2025-08-06 13:16:39 +02:00
Changed FingersCrossedHandler to use handleBatch when the buffer is triggered
This commit is contained in:
@@ -62,9 +62,7 @@ class FingersCrossedHandler extends AbstractHandler
|
|||||||
if (!$this->handler instanceof HandlerInterface) {
|
if (!$this->handler instanceof HandlerInterface) {
|
||||||
throw new \RuntimeException("The factory callback should return a HandlerInterface");
|
throw new \RuntimeException("The factory callback should return a HandlerInterface");
|
||||||
}
|
}
|
||||||
foreach ($this->buffer as $record) {
|
$this->handler->handleBatch($this->buffer);
|
||||||
$this->handler->handle($record);
|
|
||||||
}
|
|
||||||
$this->buffer = array();
|
$this->buffer = array();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@@ -89,4 +87,4 @@ class FingersCrossedHandler extends AbstractHandler
|
|||||||
{
|
{
|
||||||
throw new \BadMethodCallException('This method should not be called directly on the FingersCrossedHandler.');
|
throw new \BadMethodCallException('This method should not be called directly on the FingersCrossedHandler.');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user