Conditions | 1 |
Paths | 1 |
Total Lines | 14 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 2 |
CRAP Score | 1 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
18 | public function __invoke(ContainerInterface $container, string $requestedName, array $options = null): JsonFormatter |
||
19 | { |
||
20 | $options = $options ?? $this->getServiceOptions($container, $requestedName); |
||
21 | |||
22 | $formatter = new JsonFormatter( |
||
23 | $options['batch_mode'] ?? JsonFormatter::BATCH_MODE_JSON, |
||
24 | $options['append_new_line'] ?? true, |
||
25 | $options['ignore_empty_context_and_extra'] ?? false, |
||
26 | $options['include_stack_traces'] ?? false, |
||
27 | ); |
||
28 | 5 | ||
29 | $this->configureNormalizerFormatter($formatter, $options); |
||
30 | 5 | ||
31 | return $formatter; |
||
32 | 5 | } |
|
34 |