| Conditions | 4 | 
| Paths | 4 | 
| Total Lines | 23 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Changes | 0 | ||
| 1 | <?php  | 
            ||
| 18 | 	public function process(ContainerBuilder $container) { | 
            ||
| 19 | 		if(!$container->hasAlias(SearchService::class)) { | 
            ||
| 20 | return;  | 
            ||
| 21 | }  | 
            ||
| 22 | |||
| 23 | $serviceId = (string)$container->getAlias(SearchService::class);  | 
            ||
| 24 | |||
| 25 | 		if(!$container->hasDefinition($serviceId)) { | 
            ||
| 26 | return;  | 
            ||
| 27 | }  | 
            ||
| 28 | |||
| 29 | $definition = $container->getDefinition($serviceId);  | 
            ||
| 30 | |||
| 31 | $servicesMap = array();  | 
            ||
| 32 | // Builds an array with fully-qualified type class names as keys and service IDs as values  | 
            ||
| 33 | 		foreach($container->findTaggedServiceIds(FacetServiceInterface::TAG_NAME, true) as $serviceId => $tag) { | 
            ||
| 34 | // Add form type service to the service locator  | 
            ||
| 35 | $serviceDefinition = $container->getDefinition($serviceId);  | 
            ||
| 36 | $servicesMap[$serviceDefinition->getClass()] = new Reference($serviceId);  | 
            ||
| 37 | $servicesMap[$serviceId] = new Reference($serviceId);  | 
            ||
| 38 | }  | 
            ||
| 39 | 		$definition->addMethodCall('setFacetContainer', [ServiceLocatorTagPass::register($container, $servicesMap)]); | 
            ||
| 40 | }  | 
            ||
| 41 | }  |