Skip to content

Remove SORT_REGULAR flag from unique rule #1534

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

Open
wants to merge 1 commit into
base: 2.4
Choose a base branch
from

Conversation

dvdheiden
Copy link

Closes #1533

@henriquemoody
Copy link
Member

Thank you for your pull request, @dvdheiden!

A few changes before we merge your code. Could you add some tests to cover the new changes and write the reason for the change in the body of the commit message?

@dvdheiden
Copy link
Author

dvdheiden commented Mar 31, 2025

Hi @henriquemoody

I've already added the testcase from the issue to the tests, see: https://github.com/Respect/Validation/pull/1534/files#diff-d86b663dae78d131902ff8c8552a2df8fdf484cb3f882aacd0616e3dbfb0493aR38 which covers this specific problem.

I've added the commit message body as you requested.

@henriquemoody
Copy link
Member

Thank you so much! However, it seems like you have 3 commits now instead of 1 with the description, I think you will need to rebase your branch

When SORT_REGULAR is provided to array_unique, it does a loose comparison which makes it think ’14.1’ and ’14.10’ are the same.
@dvdheiden dvdheiden reopened this Apr 1, 2025
@dvdheiden
Copy link
Author

Done

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.

Unique rule has an issue with SORT_REGULAR flag
2 participants