Skip to content

Commit

Permalink
Updated Rector to commit 9a44c19598a21aff4b6b38f9a0db3b5ca30337c6
Browse files Browse the repository at this point in the history
rectorphp/rector-src@9a44c19 [Transform] Transform rules() to withRules() on RectorConfigBuilderRector (#5566)
  • Loading branch information
TomasVotruba committed Feb 6, 2024
1 parent 428336c commit 64d401b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
use Rector\Rector\AbstractRector;
use Symplify\RuleDocGenerator\ValueObject\CodeSample\CodeSample;
use Symplify\RuleDocGenerator\ValueObject\RuleDefinition;
use RectorPrefix202402\Webmozart\Assert\Assert;
/**
* @see \Rector\Tests\Transform\Rector\FileWithoutNamespace\RectorConfigBuilderRector\RectorConfigBuilderRectorTest
*/
Expand Down Expand Up @@ -89,6 +90,9 @@ public function refactor(Node $node) : ?Node
}
if ($this->isName($rectorConfigStmt->expr->name, 'rule')) {
$rules->items[] = new ArrayItem($rectorConfigStmt->expr->getArgs()[0]->value);
} elseif ($this->isName($rectorConfigStmt->expr->name, 'rules')) {
Assert::isAOf($rectorConfigStmt->expr->getArgs()[0]->value, Array_::class);
$rules->items = \array_merge($rules->items, $rectorConfigStmt->expr->getArgs()[0]->value->items);
} else {
// implementing method by method
return null;
Expand Down
4 changes: 2 additions & 2 deletions src/Application/VersionResolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ final class VersionResolver
* @api
* @var string
*/
public const PACKAGE_VERSION = '09398c3d4f07bb6ad664a55b87cab955278a467e';
public const PACKAGE_VERSION = '9a44c19598a21aff4b6b38f9a0db3b5ca30337c6';
/**
* @api
* @var string
*/
public const RELEASE_DATE = '2024-02-05 17:05:25';
public const RELEASE_DATE = '2024-02-06 13:21:14';
/**
* @var int
*/
Expand Down

0 comments on commit 64d401b

Please sign in to comment.