/** {@inheritdoc} */ public function build(ContainerBuilder $container) { if ($container instanceof ExtendedContainerBuilder) { $container->addCompilerPass(new ListenerExcludeSearchConnectionPass()); $container->moveCompilerPassBefore('Oro\\Bundle\\SearchBundle\\DependencyInjection\\Compiler\\ListenerExcludeSearchConnectionPass', 'Oro\\Bundle\\PlatformBundle\\DependencyInjection\\Compiler\\UpdateDoctrineEventHandlersPass'); } }
/** * {@inheritdoc} */ public function build(ContainerBuilder $container) { $container->addCompilerPass(new LazyServicesCompilerPass(), PassConfig::TYPE_AFTER_REMOVING); $container->addCompilerPass(new OptionalListenersCompilerPass(), PassConfig::TYPE_AFTER_REMOVING); // @todo: Oro\Bundle\EntityConfigBundle\DependencyInjection\Utils\ServiceLink is used to avoid BC break $container->addCompilerPass(new ServiceLinkCompilerPass('oro_service_link', 'Oro\\Bundle\\EntityConfigBundle\\DependencyInjection\\Utils\\ServiceLink')); if ($container instanceof ExtendedContainerBuilder) { $container->addCompilerPass(new UpdateDoctrineEventHandlersPass()); $container->moveCompilerPassBefore('Oro\\Bundle\\PlatformBundle\\DependencyInjection\\Compiler\\UpdateDoctrineEventHandlersPass', 'Symfony\\Bridge\\Doctrine\\DependencyInjection\\CompilerPass\\RegisterEventListenersAndSubscribersPass'); } }