Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/Illuminate/Console/Application.php
Original file line number Diff line number Diff line change
Expand Up @@ -206,9 +206,9 @@ public function output()
* Add a command to the console.
*
* @param \Symfony\Component\Console\Command\Command $command
* @return \Symfony\Component\Console\Command\Command
* @return \Symfony\Component\Console\Command\Command|null
*/
public function add(SymfonyCommand $command)
public function add(SymfonyCommand $command):?\Symfony\Component\Console\Command\Command
{
if ($command instanceof Command) {
$command->setLaravel($this->laravel);
Expand Down
2 changes: 1 addition & 1 deletion src/Illuminate/Console/Command.php
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ public function run(InputInterface $input, OutputInterface $output): int
* @param \Symfony\Component\Console\Output\OutputInterface $output
* @return int
*/
protected function execute(InputInterface $input, OutputInterface $output)
protected function execute(InputInterface $input, OutputInterface $output):int
{
if ($this instanceof Isolatable && $this->option('isolated') !== false &&
! $this->commandIsolationMutex()->create($this)) {
Expand Down
6 changes: 3 additions & 3 deletions src/Illuminate/Console/OutputStyle.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public function askQuestion(Question $question): mixed
/**
* {@inheritdoc}
*/
public function write(string|iterable $messages, bool $newline = false, int $options = 0)
public function write(string|iterable $messages, bool $newline = false, int $options = 0):void
{
$this->newLinesWritten = $this->trailingNewLineCount($messages) + (int) $newline;
$this->newLineWritten = $this->newLinesWritten > 0;
Expand All @@ -77,7 +77,7 @@ public function write(string|iterable $messages, bool $newline = false, int $opt
*
* @return void
*/
public function writeln(string|iterable $messages, int $type = self::OUTPUT_NORMAL)
public function writeln(string|iterable $messages, int $type = self::OUTPUT_NORMAL):void
{
$this->newLinesWritten = $this->trailingNewLineCount($messages) + 1;
$this->newLineWritten = true;
Expand All @@ -90,7 +90,7 @@ public function writeln(string|iterable $messages, int $type = self::OUTPUT_NORM
*
* @return void
*/
public function newLine(int $count = 1)
public function newLine(int $count = 1):void
{
$this->newLinesWritten += $count;
$this->newLineWritten = $this->newLinesWritten > 0;
Expand Down
2 changes: 1 addition & 1 deletion src/Illuminate/Console/QuestionHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class QuestionHelper extends SymfonyQuestionHelper
*
* @return void
*/
protected function writePrompt(OutputInterface $output, Question $question)
protected function writePrompt(OutputInterface $output, Question $question):void
{
$text = OutputFormatter::escapeTrailingBackslash($question->getQuestion());

Expand Down
2 changes: 1 addition & 1 deletion src/Illuminate/Foundation/Console/ClosureCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public function __construct($signature, Closure $callback)
* @param \Symfony\Component\Console\Output\OutputInterface $output
* @return int
*/
protected function execute(InputInterface $input, OutputInterface $output)
protected function execute(InputInterface $input, OutputInterface $output):int
{
$inputs = array_merge($input->getArguments(), $input->getOptions());

Expand Down
2 changes: 1 addition & 1 deletion src/Illuminate/Testing/ParallelConsoleOutput.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public function __construct($output)
* @param int $options
* @return void
*/
public function write($messages, bool $newline = false, int $options = 0)
public function write($messages, bool $newline = false, int $options = 0):void
{
$messages = collect($messages)->filter(function ($message) {
return ! Str::contains($message, $this->ignore);
Expand Down