Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the new ReplaceAtMethodWithDesiredMatcherRector rule #454

Merged
merged 2 commits into from
Feb 1, 2025

Conversation

hans-thomas
Copy link
Contributor

@hans-thomas hans-thomas commented Feb 1, 2025

closes #439

@TomasVotruba
Copy link
Member

Looks great, thank you 🥳

@TomasVotruba TomasVotruba merged commit e991afe into rectorphp:main Feb 1, 2025
6 checks passed
}

if ($node->var instanceof MethodCall && $arg = $this->findAtMethodCall($node->var)) {
$this->replaceWithDesiredMatcher($arg);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

return $node is needed after node changed, the flag like $hasChanged is needed for it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Rector doesn't support PHPUnit 9.3 deprecation at() matcher
3 participants