[DI] Minor dumping logic simplification
This commit is contained in:
parent
5c2797afd3
commit
37d8495a59
@ -1608,7 +1608,7 @@ EOF;
|
||||
$code = sprintf('$this->get(\'%s\')', $id);
|
||||
}
|
||||
|
||||
if ($this->container->hasDefinition($id) && (!$this->container->getDefinition($id)->isPublic() || $this->container->getDefinition($id)->isShared())) {
|
||||
if ($this->container->hasDefinition($id) && $this->container->getDefinition($id)->isShared()) {
|
||||
// The following is PHP 5.5 syntax for what could be written as "(\$this->services['$id'] ?? $code)" on PHP>=7.0
|
||||
|
||||
$code = "\${(\$_ = isset(\$this->services['$id']) ? \$this->services['$id'] : $code) && false ?: '_'}";
|
||||
|
Reference in New Issue
Block a user