Skip to content

Commit f817279

Browse files
[8.x] Add strict parameter to distinct validation rule (#6941)
* Add strict to disctinct validation rule * Update validation.md Co-authored-by: Taylor Otwell <[email protected]>
1 parent a6e4e8e commit f817279

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

validation.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -883,6 +883,10 @@ When validating arrays, the field under validation must not have any duplicate v
883883

884884
'foo.*.id' => 'distinct'
885885

886+
Distinct uses loose variable comparisons by default. To use strict comparisons, you may add the `strict` parameter to your validation rule definition:
887+
888+
'foo.*.id' => 'distinct:strict'
889+
886890
You may add `ignore_case` to the validation rule's arguments to make the rule ignore capitalization differences:
887891

888892
'foo.*.id' => 'distinct:ignore_case'

0 commit comments

Comments
 (0)