1
0
mirror of https://github.com/Seldaek/monolog.git synced 2025-10-22 09:06:10 +02:00

Introduce a depth parameter for normalization to limit stack nesting

This commit is contained in:
Nils Adermann
2016-06-22 14:36:16 +02:00
parent c582a6e791
commit 50232e7bb4
3 changed files with 14 additions and 6 deletions

View File

@@ -102,12 +102,12 @@ class WildfireFormatter extends NormalizerFormatter
throw new \BadMethodCallException('Batch formatting does not make sense for the WildfireFormatter');
}
protected function normalize($data)
protected function normalize($data, $depth = 0)
{
if (is_object($data) && !$data instanceof \DateTime) {
return $data;
}
return parent::normalize($data);
return parent::normalize($data, $depth);
}
}