File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -251,13 +251,18 @@ each with a single field.
251
251
``ignoreNull ``
252
252
~~~~~~~~~~~~~~
253
253
254
- **type **: ``boolean `` **default **: ``true ``
254
+ **type **: ``boolean `` | `` array `` | `` string `` **default **: ``true ``
255
255
256
256
If this option is set to ``true ``, then the constraint will allow multiple
257
257
entities to have a ``null `` value for a field without failing validation.
258
258
If set to ``false ``, only one ``null `` value is allowed - if a second entity
259
259
also has a ``null `` value, validation would fail.
260
260
261
+ As of Symfony 6.3, the ``UniqueEntity `` constraint allows you to ignore null
262
+ values on specific fields when checking for uniqueness. This feature can be
263
+ helpful when you want to validate the uniqueness of a combination of fields,
264
+ but want to exclude combinations where one or more of the fields are null.
265
+
261
266
``message ``
262
267
~~~~~~~~~~~
263
268
You can’t perform that action at this time.
0 commit comments