We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 818849d commit 9e7fc19Copy full SHA for 9e7fc19
DependencyInjection/Compiler/ExceptionListenerPass.php
@@ -28,9 +28,11 @@ public function process(ContainerBuilder $container)
28
}
29
30
// register the exception controller only if Twig is enabled
31
- $engines = $container->getParameter('templating.engines');
32
- if (!in_array('twig', $engines)) {
33
- $container->removeDefinition('twig.exception_listener');
+ if ($container->hasParameter('templating.engines')) {
+ $engines = $container->getParameter('templating.engines');
+ if (!in_array('twig', $engines)) {
34
+ $container->removeDefinition('twig.exception_listener');
35
+ }
36
37
38
0 commit comments