Made `debug:container` and `debug:autowiring` ignore starting backslash in service id
This commit is contained in:
parent
454574b0a3
commit
0945f27e81
|
@ -220,6 +220,8 @@ EOF
|
|||
|
||||
private function findProperServiceName(InputInterface $input, SymfonyStyle $io, ContainerBuilder $builder, string $name, bool $showHidden)
|
||||
{
|
||||
$name = ltrim($name, '\\');
|
||||
|
||||
if ($builder->has($name) || !$input->isInteractive()) {
|
||||
return $name;
|
||||
}
|
||||
|
|
|
@ -85,6 +85,7 @@ class ContainerDebugCommandTest extends WebTestCase
|
|||
return [
|
||||
[BackslashClass::class],
|
||||
['FixturesBackslashClass'],
|
||||
['\\'.BackslashClass::class],
|
||||
];
|
||||
}
|
||||
}
|
||||
|
|
Reference in New Issue