@@ -36,28 +36,28 @@ discard block |
||
| 36 | 36 | public function __construct( |
| 37 | 37 | private readonly ConfiguratorInterface $config, |
| 38 | 38 | private readonly EnvironmentInterface $env, |
| 39 | - ) { |
|
| 39 | + ){ |
|
| 40 | 40 | } |
| 41 | 41 | |
| 42 | 42 | public function init(Container $container, FinalizerInterface $finalizer): void |
| 43 | 43 | { |
| 44 | 44 | $finalizer->addFinalizer(static function (bool $terminate) use ($container): void { |
| 45 | - if ($terminate) { |
|
| 45 | + if ($terminate){ |
|
| 46 | 46 | return; |
| 47 | 47 | } |
| 48 | 48 | |
| 49 | - if ($container->hasInstance(LoggerInterface::class)) { |
|
| 49 | + if ($container->hasInstance(LoggerInterface::class)){ |
|
| 50 | 50 | $logger = $container->get(LoggerInterface::class); |
| 51 | 51 | |
| 52 | - if ($logger instanceof ResettableInterface) { |
|
| 52 | + if ($logger instanceof ResettableInterface){ |
|
| 53 | 53 | $logger->reset(); |
| 54 | 54 | } |
| 55 | 55 | } |
| 56 | 56 | |
| 57 | - if ($container->hasInstance(LogsInterface::class)) { |
|
| 57 | + if ($container->hasInstance(LogsInterface::class)){ |
|
| 58 | 58 | $factory = $container->get(LogsInterface::class); |
| 59 | 59 | |
| 60 | - if ($factory instanceof ResettableInterface) { |
|
| 60 | + if ($factory instanceof ResettableInterface){ |
|
| 61 | 61 | $factory->reset(); |
| 62 | 62 | } |
| 63 | 63 | } |
@@ -74,14 +74,14 @@ discard block |
||
| 74 | 74 | |
| 75 | 75 | public function addHandler(string $channel, HandlerInterface $handler): void |
| 76 | 76 | { |
| 77 | - if (!isset($this->config->getConfig(MonologConfig::CONFIG)['handlers'][$channel])) { |
|
| 77 | + if (!isset($this->config->getConfig(MonologConfig::CONFIG)['handlers'][$channel])){ |
|
| 78 | 78 | $this->config->modify(MonologConfig::CONFIG, new Append('handlers', $channel, [])); |
| 79 | 79 | } |
| 80 | 80 | |
| 81 | 81 | $this->config->modify( |
| 82 | 82 | MonologConfig::CONFIG, |
| 83 | 83 | new Append( |
| 84 | - 'handlers.' . $channel, |
|
| 84 | + 'handlers.'.$channel, |
|
| 85 | 85 | null, |
| 86 | 86 | $handler |
| 87 | 87 | ) |