Conditions | 6 |
Paths | 4 |
Total Lines | 12 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 8 |
CRAP Score | 6 |
Changes | 2 | ||
Bugs | 1 | Features | 0 |
1 | <?php |
||
26 | 10 | public function process(ContainerBuilder $container) |
|
27 | { |
||
28 | 10 | if ($container->has('fos_rest.converter.request_body') && !$container->has('sensio_framework_extra.converter.listener')) { |
|
29 | 1 | throw new \RuntimeException('You need to enable the parameter converter listeners in SensioFrameworkExtraBundle when using the FOSRestBundle RequestBodyParamConverter'); |
|
30 | } |
||
31 | |||
32 | 9 | if ($container->has('fos_rest.view_response_listener') && isset($container->getParameter('kernel.bundles')['SensioFrameworkExtraBundle'])) { |
|
33 | 4 | if (!$container->has('sensio_framework_extra.view.listener')) { |
|
34 | 1 | throw new \RuntimeException('You must enable the SensioFrameworkExtraBundle view annotations to use the ViewResponseListener.'); |
|
35 | } |
||
36 | 3 | } |
|
37 | 8 | } |
|
38 | } |
||
39 |