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

[Doc] Use fnmatch() instead of $this->isName($node->name, 'set*') in docuemntation create custom rule #1654

Merged
merged 2 commits into from
Sep 10, 2023

Conversation

samsonasik
Copy link
Member

@samsonasik
Copy link
Member Author

All checks have passed 🎉 @TomasVotruba I am merging it ;)

@TomasVotruba
Copy link
Member

Perfect, thanks 👍

// we only care about "set*" method names
if (! $this->isName($node->name, 'set*')) {
if (! fnmatch('set*', $nodeName, FNM_NOESCAPE)) {
Copy link
Member

Choose a reason for hiding this comment

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

Here str_starts_with() would be better choice 👍 (I'm on phone now, so lazy to send PR)

Copy link
Member Author

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.

None yet

2 participants