Skip to content

Commit ca04555

Browse files
committed
Improved format of message and added missing information.
1 parent b9e375c commit ca04555

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

reference/forms/types/collection.rst

+9-7
Original file line numberDiff line numberDiff line change
@@ -268,18 +268,20 @@ delete_empty
268268

269269
**type**: ``Boolean`` **default**: ``false``
270270

271-
.. caution::
272-
273-
Delete empty will only remove items when the normalized value is null.
274-
If your `type`_ is a compound form type, you need to have the :ref:`required <reference-form-option-required>`
275-
option set to ``false`` inside `options`_, See :ref:`empty_data <reference-form-option-empty-data>`.
276-
277-
278271
If you want to explicitly remove entirely empty collection entries from your
279272
form you have to set this option to true. However, existing collection entries
280273
will only be deleted if you have the allow_delete_ option enabled. Otherwise
281274
the empty values will be kept.
282275

276+
.. caution::
277+
278+
The ``delete_empty`` option will only remove items when the normalized
279+
value is null. If your `type`_ is a compound form type, you need to have
280+
the ``required`` option set to false or ``empty_data`` option explicitly
281+
set to null, both these options can be set inside `options`_. To
282+
understand why this is necessary, see form
283+
:ref:`empty_data <reference-form-option-empty-data>`.
284+
283285
options
284286
~~~~~~~
285287

0 commit comments

Comments
 (0)