| Conditions | 2 |
| Paths | 1 |
| Total Lines | 11 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 2 |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 25 | 6 | public function create(ContainerInterface $container): LoggerInterface |
|
| 26 | { |
||
| 27 | 6 | $logger = new Logger('App'); |
|
| 28 | 6 | $config = $container->get('config'); |
|
| 29 | |||
| 30 | 5 | $logger->pushHandler(new StreamHandler( |
|
| 31 | 5 | $config['log_file'], |
|
| 32 | 5 | $config['debug'] ? Logger::DEBUG : Logger::WARNING |
|
| 33 | 5 | )); |
|
| 34 | |||
| 35 | 5 | return $logger; |
|
| 36 | } |
||
| 38 |