Skip to content

Commit 920609b

Browse files
committed
Use constants for the command status code
1 parent b5c0341 commit 920609b

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

components/console/helpers/questionhelper.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ the following to your command::
4040
$question = new ConfirmationQuestion('Continue with this action?', false);
4141

4242
if (!$helper->ask($input, $output, $question)) {
43-
return 0;
43+
return Command::SUCCESS;
4444
}
4545
}
4646
}

console/commands_as_services.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ For example, suppose you want to log something from within your command::
4545
{
4646
$this->logger->info('Waking up the sun');
4747
// ...
48-
49-
return 0;
48+
49+
return Command::SUCCESS;
5050
}
5151
}
5252

console/input.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ You now have access to a ``last_name`` argument in your command::
5252
}
5353

5454
$output->writeln($text.'!');
55-
56-
return 0;
55+
56+
return Command::SUCCESS;
5757
}
5858
}
5959

0 commit comments

Comments
 (0)