Skip to content

Commit 83b1d71

Browse files
committed
bug #37774 [Console] Make sure we pass a numeric array of arguments to call_user_func_array() (derrabus)
This PR was merged into the 3.4 branch. Discussion ---------- [Console] Make sure we pass a numeric array of arguments to call_user_func_array() | Q | A | ------------- | --- | Branch? | 3.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | N/A | License | MIT | Doc PR | N/A On php 8, the unit tests fail with the following error: ``` ArgumentCountError: array_merge() does not accept unknown named parameters ``` This PR should fix the issue. Commits ------- 67102c3 [Console] Make sure we pass a numeric array of arguments to call_user_func_array().
2 parents 5c67272 + 67102c3 commit 83b1d71

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/Console/Descriptor/TextDescriptor.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ protected function describeApplication(Application $application, array $options
204204
// calculate max. width based on available commands per namespace
205205
$width = $this->getColumnWidth(\call_user_func_array('array_merge', array_map(function ($namespace) use ($commands) {
206206
return array_intersect($namespace['commands'], array_keys($commands));
207-
}, $namespaces)));
207+
}, array_values($namespaces))));
208208

209209
if ($describedNamespace) {
210210
$this->writeText(sprintf('<comment>Available commands for the "%s" namespace:</comment>', $describedNamespace), $options);

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy