[FrameworkBundle] fixed registration of the register listener pass

This commit is contained in:
Fabien Potencier 2013-09-12 14:08:32 +02:00
parent 6ec2cbaa6c
commit 427ee19195
1 changed files with 3 additions and 1 deletions

View File

@ -60,7 +60,9 @@ class FrameworkBundle extends Bundle
$container->addCompilerPass(new RoutingResolverPass());
$container->addCompilerPass(new ProfilerPass());
$container->addCompilerPass(new RegisterKernelListenersPass(), PassConfig::TYPE_AFTER_REMOVING);
// must be registered before removing private services as some might be listeners/subscribers
// but as late as possible to get resolved parameters
$container->addCompilerPass(new RegisterKernelListenersPass(), PassConfig::TYPE_BEFORE_REMOVING);
$container->addCompilerPass(new TemplatingPass());
$container->addCompilerPass(new AddConstraintValidatorsPass());
$container->addCompilerPass(new AddValidatorInitializersPass());