8000 bug #46434 [FrameworkBundle] Fix BC break in abstract config commands… · symfony/symfony@826a5d4 · GitHub
[go: up one dir, main page]

Skip to content

Commit 826a5d4

Browse files
committed
bug #46434 [FrameworkBundle] Fix BC break in abstract config commands (yceruto)
This PR was merged into the 4.4 branch. Discussion ---------- [FrameworkBundle] Fix BC break in abstract config commands | Q | A | ------------- | --- | Branch? | 4.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | - | License | MIT | Doc PR | - Fixes #46412 This revert also the unnecessary changes made in ConfigDebugCommand and ConfigDumpReferenceCommand classes Commits ------- 5be61fa Fix BC break
2 parents 8948784 + 5be61fa commit 826a5d4

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

src/Symfony/Bundle/FrameworkBundle/Command/AbstractConfigCommand.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
use Symfony\Component\Console\Helper\Table;
1717
use Symfony\Component\Console\Output\OutputInterface;
1818
use Symfony\Component\Console\Style\StyleInterface;
19-
use Symfony\Component\DependencyInjection\ContainerBuilder;
2019
use Symfony\Component\DependencyInjection\Extension\ExtensionInterface;
2120< 8000 /td>

2221
/**
@@ -60,7 +59,7 @@ protected function listBundles($output)
6059
/**
6160
* @return ExtensionInterface
6261
*/
63-
protected function findExtension($name, ContainerBuilder $container)
62+
protected function findExtension($name)
6463
{
6564
$bundles = $this->initializeBundles();
6665
$minScore = \INF;
@@ -82,6 +81,8 @@ protected function findExtension($name, ContainerBuilder $container)
8281
}
8382
}
8483

84+
$container = $this->getContainerBuilder();
85+
8586
if ($container->hasExtension($name)) {
8687
return $container->getExtension($name);
8788
}

src/Symfony/Bundle/FrameworkBundle/Command/ConfigDebugCommand.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,9 @@ protected function execute(InputInterface $input, OutputInterface $output): int
7979
return 0;
8080
}
8181

82-
$container = $this->compileContainer();
83-
$extension = $this->findExtension($name, $container);
82+
$extension = $this->findExtension($name);
8483
$extensionAlias = $extension->getAlias();
84+
$container = $this->compileContainer();
8585

8686
$config = $container->resolveEnvPlaceholders(
8787
$container->getParameterBag()->resolveValue(

src/Symfony/Bundle/FrameworkBundle/Command/ConfigDumpReferenceCommand.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -89,10 +89,9 @@ protected function execute(InputInterface $input, OutputInterface $output): int
8989
return 0;
9090
}
9191

92-
$container = $this->getContainerBuilder();
93-
$extension = $this->findExtension($name, $container);
92+
$extension = $this->findExtension($name);
9493

95-
$configuration = $extension->getConfiguration([], $container);
94+
$configuration = $extension->getConfiguration([], $this->getContainerBuilder());
9695

9796
$this->validateConfiguration($extension, $configuration);
9897

0 commit comments

Comments
 (0)
0