bug #34888 [TwigBundle] add tags before processing them (xabbuh)

This PR was merged into the 3.4 branch.

Discussion
----------

[TwigBundle] add tags before processing them

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #34815
| License       | MIT
| Doc PR        |

Commits
-------

e1145a78b5 add tags before processing them
This commit is contained in:
Christian Flothmann 2019-12-09 17:39:04 +01:00
commit bf877b811c

View File

@ -32,7 +32,8 @@ class TwigBundle extends Bundle
{
parent::build($container);
$container->addCompilerPass(new ExtensionPass());
// ExtensionPass must be run before the FragmentRendererPass as it adds tags that are processed later
$container->addCompilerPass(new ExtensionPass(), PassConfig::TYPE_BEFORE_OPTIMIZATION, 10);
$container->addCompilerPass(new TwigEnvironmentPass());
$container->addCompilerPass(new TwigLoaderPass());
$container->addCompilerPass(new ExceptionListenerPass());