8000 bug #47907 [Console] Update Application.php (aleksandr-shevchenko) · symfony/symfony@b3a0efc · GitHub
[go: up one dir, main page]

Skip to content

Commit b3a0efc

Browse files
committed
bug #47907 [Console] Update Application.php (aleksandr-shevchenko)
This PR was merged into the 4.4 branch. Discussion ---------- [Console] Update Application.php | Q | A | ------------- | --- | Branch? | 4.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | - | License | MIT | Doc PR | - #47862 (comment) Commits ------- c27f90e Update Application.php
2 parents ab793bb + c27f90e commit b3a0efc

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/Symfony/Component/Console/Application.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,9 @@ public function doRun(InputInterface $input, OutputInterface $output)
254254
$alternative = $alternatives[0];
255255

256256
$style = new SymfonyStyle($input, $output);
257-
$style->block(sprintf('Command "%s" is not defined.', $name), null, 'error', ' ', true);
257+
$output->writeln('');
258+
$formattedBlock = (new FormatterHelper())->formatBlock(sprintf('Command "%s" is not defined.', $name), 'error', true);
259+
$output->writeln($formattedBlock);
258260
if (!$style->confirm(sprintf('Do you want to run "%s" instead? ', $alternative), false)) {
259261
if (null !== $this->dispatcher) {
260262
$event = new ConsoleErrorEvent($input, $output, $e);

0 commit comments

Comments
 (0)
0