Skip to content

Commit b24b5f0

Browse files
Merge branch '4.4' into 5.3
* 4.4: Fix tests on PHP 8.1 [Cache] Fix memory leak [DependencyInjection] fix inlining when non-shared services are involved [DoctrineBridge] add support for the JSON type [PHPUnitBridge] Fix Uncaught ValueError [FrameworkBundle] fix registering late resettable services [Validator] Missing translations for Greek (el) translate for japanese 101,102,103 [HttpClient] Curl http client has to reinit curl multi handle on reset [Validator] Add Swedish translation for issue #43737
2 parents be833dd + 3916560 commit b24b5f0

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

Compiler/InlineServiceDefinitionsPass.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ private function isInlineableDefinition(string $id, Definition $definition): boo
176176
$srcId = $edge->getSourceNode()->getId();
177177
$this->connectedIds[$srcId] = true;
178178
if ($edge->isWeak() || $edge->isLazy()) {
179-
return false;
179+
return !$this->connectedIds[$id] = true;
180180
}
181181
}
182182

@@ -198,9 +198,7 @@ private function isInlineableDefinition(string $id, Definition $definition): boo
198198

199199
$srcIds = [];
200200
$srcCount = 0;
201-
$isReferencedByConstructor = false;
202201
foreach ($this->graph->getNode($id)->getInEdges() as $edge) {
203-
$isReferencedByConstructor = $isReferencedByConstructor || $edge->isReferencedByConstructor();
204202
$srcId = $edge->getSourceNode()->getId();
205203
$this->connectedIds[$srcId] = true;
206204
if ($edge->isWeak() || $edge->isLazy()) {

0 commit comments

Comments
 (0)