Commit f0c6c79
committed
bug #62586 [DependencyInjection][FrameworkBundle] fix BC break when dumping container for build/lint commands (aschempp)
This PR was squashed before being merged into the 7.4 branch.
Discussion
----------
[DependencyInjection][FrameworkBundle] fix BC break when dumping container for build/lint commands
| Q | A
| ------------- | ---
| Branch? | 7.4
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Issues |
| License | MIT
#60597 introduced a BC break in that it assumes the `ContainerBuilder` constructor accepts the parameter bag as its first argument. However, in our application, we have a custom version of the `ContainerBuilder`.
Since the container is already built at this state, I understand that calling `__construct()` again is just a hack to re-set the parameter bag. A direct setter function for this case should fix the issue.
PS: `Kernel::buildContainer` must always return an instance of `ContainerBuilder`, so the setter method must always be there (our class inherits from it as well).
Links:
- Original issue: contao/contao#9058
- Custom `ContainerBuilder` https://github.com/contao/manager-plugin/blob/main/src/Config/ContainerBuilder.php
Commits
-------
843fbca [DependencyInjection][FrameworkBundle] fix BC break when dumping container for build/lint commandsFile tree
1 file changed
+4
-1
lines changed- src/Symfony/Bundle/FrameworkBundle/Command
1 file changed
+4
-1
lines changedLines changed: 4 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
67 | | - | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
68 | 71 | | |
69 | 72 | | |
70 | 73 | | |
| |||
0 commit comments