Skip to content

Commit

Permalink
chore: update PHP-CS-Fixer configuration
Browse files Browse the repository at this point in the history
- Updated PHP-CS-Fixer configuration to disable empty parentheses for attributes
  • Loading branch information
guanguans committed Apr 11, 2024
1 parent 24837e4 commit 55ffe8d
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 6 deletions.
3 changes: 3 additions & 0 deletions .php-cs-fixer.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@
'align_multiline_comment' => [
'comment_type' => 'phpdocs_only',
],
'attribute_empty_parentheses' => [
'use_parentheses' => false,
],
'blank_line_before_statement' => [
'statements' => [
'break',
Expand Down
2 changes: 1 addition & 1 deletion app/Commands/Command.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ abstract class Command extends \Illuminate\Console\Command
*
* @throws \Symfony\Component\Console\Exception\InvalidArgumentException
*/
#[\Override()]
#[\Override]
protected function execute(InputInterface $input, OutputInterface $output): int
{
if ($this->validator()->fails()) {
Expand Down
7 changes: 6 additions & 1 deletion app/Commands/FeedCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ final class FeedCommand extends Command

public function handle(): void
{
/** @noinspection NullPointerExceptionInspection */
str(File::get($this->option('from')))
->after(self::FLAG)
->prepend(self::FLAG)
Expand Down Expand Up @@ -82,10 +83,14 @@ static function (Collection $carry, string $line) use (&$date): Collection {
});
}

#[\Override()]
/**
* @noinspection MethodVisibilityInspection
*/
#[\Override]
protected function rules(): array
{
return [
'from' => 'required|string',
];
}

Expand Down
2 changes: 1 addition & 1 deletion app/Commands/InspireCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public function handle(): void
/**
* Define the command's schedule.
*/
#[\Override()]
#[\Override]
public function schedule(Schedule $schedule): void
{
// $schedule->command(static::class)->everyMinute();
Expand Down
2 changes: 1 addition & 1 deletion app/Providers/AppServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,6 @@ public function boot(): void {}
/**
* Register any application services.
*/
#[\Override()]
#[\Override]
public function register(): void {}
}
4 changes: 2 additions & 2 deletions tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ abstract class TestCase extends BaseTestCase
/**
* This method is called before each test.
*/
#[\Override()]
#[\Override]
protected function setUp(): void
{
parent::setUp();
Expand All @@ -33,7 +33,7 @@ protected function setUp(): void
/**
* This method is called after each test.
*/
#[\Override()]
#[\Override]
protected function tearDown(): void
{
parent::tearDown();
Expand Down

0 comments on commit 55ffe8d

Please sign in to comment.