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

Improve typing of filters that do not accept non-falsy strings #2620

Merged
merged 3 commits into from Sep 18, 2023
Merged

Improve typing of filters that do not accept non-falsy strings #2620

merged 3 commits into from Sep 18, 2023

Conversation

zonuexe
Copy link
Contributor

@zonuexe zonuexe commented Sep 12, 2023

The following four filters accept neither '' nor '0', so their values can be typed as non-falsy-string.

  • FILTER_VALIDATE_EMAIL
  • FILTER_VALIDATE_IP
  • FILTER_VALIDATE_MAC
  • FILTER_VALIDATE_URL

https://3v4l.org/vtE6a

@phpstan-bot
Copy link
Collaborator

You've opened the pull request against the latest branch 1.11.x. If your code is relevant on 1.10.x and you want it to be released sooner, please rebase your pull request and change its target to 1.10.x.

@zonuexe zonuexe changed the base branch from 1.11.x to 1.10.x September 12, 2023 17:50
@ondrejmirtes ondrejmirtes merged commit b8d819c into phpstan:1.10.x Sep 18, 2023
412 of 415 checks passed
@ondrejmirtes
Copy link
Member

Thank you!

@zonuexe zonuexe deleted the improve-filter-var-non-falsy branch September 20, 2023 01:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants