8000 bug #36622 [DI] limit recursivity of ResolveNoPreloadPass (nicolas-gr… · symfony/symfony@75e3d75 · GitHub
[go: up one dir, main page]

Skip to content

Commit 75e3d75

Browse files
committed
bug #36622 [DI] limit recursivity of ResolveNoPreloadPass (nicolas-grekas)
This PR was merged into the 5.1-dev branch. Discussion ---------- [DI] limit recursivity of ResolveNoPreloadPass | Q | A | ------------- | --- | Branch? | master | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | - | License | MIT | Doc PR | - Let's save some nesting levels, these definitions will be processed by the main loop anyway. Commits ------- 6dd52f9 [DI] limit recursivity of ResolveNoPreloadPass
2 parents c699b9c + 6dd52f9 commit 75e3d75

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/DependencyInjection/Compiler/ResolveNoPreloadPass.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ protected function processValue($value, bool $isRoot = false)
7575
if ($value instanceof Reference && ContainerBuilder::IGNORE_ON_UNINITIALIZED_REFERENCE !== $value->getInvalidBehavior() && $this->container->has($id = (string) $value)) {
7676
$definition = $this->container->findDefinition($id);
7777

78-
if (!isset($this->resolvedIds[$id])) {
78+
if (!isset($this->resolvedIds[$id]) && (!$definition->isPublic() || $definition->isPrivate())) {
7979
$this->resolvedIds[$id] = true;
8080
$this->processValue($definition, true);
8181
}

0 commit comments

Comments
 (0)
0