Skip to content

Commit

Permalink
Fix compatibility issue with PHP 8.1 (#157)
Browse files Browse the repository at this point in the history
* Fix compatibility issue with PHP 8.1

* Code style fix

* Even more code style fixes
  • Loading branch information
ticktackk authored and PedroTroller committed Apr 27, 2022
1 parent ee80622 commit 04a84a1
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/PedroTroller/CS/Fixer/Fixers.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ final class Fixers implements IteratorAggregate
/**
* {@inheritdoc}
*/
public function getIterator()
public function getIterator(): \Generator
{
$finder = Finder::create()
->in(__DIR__)
Expand Down
2 changes: 1 addition & 1 deletion tests/Runner.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public static function run(): void
set_error_handler(
function ($type, $message, $file, $line) use (&$deprecations): void {
$deprecations[$message][] = sprintf('%s at line %d', $file, $line);
$deprecations[$message] = array_unique($deprecations[$message]);
$deprecations[$message] = array_unique($deprecations[$message]);

sort($deprecations[$message]);
},
Expand Down
2 changes: 2 additions & 0 deletions tests/UseCase/Phpspec.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ final class Phpspec implements UseCase
public function getFixers(): iterable
{
yield new VisibilityRequiredFixer();

yield new VoidReturnFixer();

yield new PhpspecFixer();
}

Expand Down

0 comments on commit 04a84a1

Please sign in to comment.