Skip to content

Commit

Permalink
[Translation] Decouple TranslatorPathsPass from "debug." convention
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolas-grekas committed Mar 6, 2023
1 parent f0ae138 commit 57b312f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions DependencyInjection/RegisterListenersPass.php
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ public function process(ContainerBuilder $container)

$dispatcherDefinition = $globalDispatcherDefinition;
if (isset($event['dispatcher'])) {
$dispatcherDefinition = $container->getDefinition($event['dispatcher']);
$dispatcherDefinition = $container->findDefinition($event['dispatcher']);
}

$dispatcherDefinition->addMethodCall('addListener', [$event['event'], [new ServiceClosureArgument(new Reference($id)), $event['method']], $priority]);
Expand Down Expand Up @@ -161,7 +161,7 @@ public function process(ContainerBuilder $container)
continue;
}

$dispatcherDefinitions[$attributes['dispatcher']] = $container->getDefinition($attributes['dispatcher']);
$dispatcherDefinitions[$attributes['dispatcher']] = $container->findDefinition($attributes['dispatcher']);
}

if (!$dispatcherDefinitions) {
Expand Down

0 comments on commit 57b312f

Please sign in to comment.