Skip to content

Commit 1031457

Browse files
authored
Show how to get $myService
1 parent 7618fb7 commit 1031457

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

service_container/service_subscribers_locators.rst

+2
Original file line numberDiff line numberDiff line change
@@ -457,6 +457,8 @@ will share identical locators among all the services referencing them::
457457
// ...
458458
'logger' => new Reference('logger'),
459459
];
460+
461+
$myService = $container->getDefinition(MyService::class);
460462

461463
$myService->addArgument(ServiceLocatorTagPass::register($container, $locateableServices));
462464
}

0 commit comments

Comments
 (0)