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

[5.8] adds Str::containsAll() method #28695

Closed
wants to merge 1 commit into from
Closed

[5.8] adds Str::containsAll() method #28695

wants to merge 1 commit into from

Conversation

chrisbbreuer
Copy link
Contributor

Hi everyone,

As discussed here #28688 - in order to avoid a breaking change, I abstracted it into a new method called containsAll().

Every now and then I run into a dilemma where I want to check if an array of values is contained within a string.

This adds the functionality to check for all array values inside a string.

Check out the tests to see all the supported scenarios.

I hope you guys find this useful, too 🙂

Chris

Hi everyone,

As discussed here #28688 - in order to avoid a breaking change, I abstracted it into a new method called `containsAll()`.

Every now and then I run into a dilemma where I want to check if an array of values is contained within a string.

This adds the functionality to check for all array values inside a string.

Check out the tests to see all the supported scenarios.

I hope you guys find this useful, too 🙂
@taylorotwell
Copy link
Member

Strange not to loop through and use existing contains logic. The checks behave differently.

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.

2 participants