BMDMSoundex
BMDMSoundex copied to clipboard
MonoLog Version 2 Issue with setFormatter() on NullHandler
Version 2 NullHandler does not accept setFormatter(), $handler must be instanceof Monolog\Handler\FormattableHandlerInterface
I placed $handler->setFormatter($formatter) in this conditions:
if (Logger::API === 1) { $handler->setFormatter($formatter); } elseif (Logger::API === 2 && $handler instanceof Monolog\Handler\FormattableHandlerInterface) { $handler->setFormatter($formatter); }