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

Filter duplicate periods in collection #96

Merged

Conversation

endelwar
Copy link
Contributor

@endelwar endelwar commented Oct 8, 2021

When we add a Period in a collection or create a new PeriodCollection from an array of Period they are added as is.

unique() deduplicates PeriodCollection->periods array, returning a new collection.

@brendt brendt merged commit 3991f28 into spatie:master Oct 13, 2021
@brendt
Copy link
Collaborator

brendt commented Oct 13, 2021

Nice one, thanks!

@brendt
Copy link
Collaborator

brendt commented Oct 13, 2021

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