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

Added Arrays::find() method #305

Closed
wants to merge 1 commit into from

Conversation

into-the-v0id
Copy link

@into-the-v0id into-the-v0id commented Nov 20, 2023

This PR adds the Arrays::find() helper. It's somewhat commonly used functionality and often inconvenient and unnecessarily verbose in raw PHP.

@dg
Copy link
Member

dg commented Nov 21, 2023

Thanks, that's a useful feature.

I'm thinking about one thing. Probably the findLast() function would come in handy over time. What about utilizing the already existing first() and last() functions and just add an optional $callback parameter to them?

@dg dg closed this in 7768aae Nov 21, 2023
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