Skip to content

Commit

Permalink
allow chaining of ->newLine() (#41327)
Browse files Browse the repository at this point in the history
```php
$this->newLine();
$this->info('Success!');
```

can now be shortened to

```php
$this->newLine()->info('Success');
```
  • Loading branch information
browner12 authored Mar 3, 2022
1 parent 44dc37a commit 5c77dac
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Illuminate/Console/Concerns/InteractsWithIO.php
Original file line number Diff line number Diff line change
Expand Up @@ -372,11 +372,13 @@ public function alert($string)
* Write a blank line.
*
* @param int $count
* @return void
* @return $this
*/
public function newLine($count = 1)
{
$this->output->newLine($count);

return $this;
}

/**
Expand Down

0 comments on commit 5c77dac

Please sign in to comment.