$loggerDefinition =
$container->
getDefinition('logger'
);
if (Logger::
class === $loggerDefinition->
getClass()) { $loggerDefinition->
setConfigurator([__CLASS__, 'configureLogger'
]);
} } public static function configureLogger(Logger
$logger): void
{ if (!\
in_array(\PHP_SAPI,
['cli', 'phpdbg'
], true
)) { $logger->
enableDebug();
} }}