8000 minor #17728 Fix `empty_data` option description of `TextareaType` (c… · symfony/symfony-docs@fee323e · GitHub
[go: up one dir, main page]

Skip to content

Commit fee323e

Browse files
committed
minor #17728 Fix empty_data option description of TextareaType (chapa)
This PR was merged into the 5.4 branch. Discussion ---------- Fix `empty_data` option description of `TextareaType` The `empty_data` option behave the same for `TextareaType` and `TextType` but the description of the option for `TextareaType` is wrong. This PR replace the description of the `empty_data` option of `TextareaType` by the one of `TextType` (see 5cfff92) Commits ------- 4e51357 Fix empty_data option description of TextareaType
2 parents 730070c + 4e51357 commit fee323e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

reference/forms/types/textarea.rst

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,9 @@ These options inherit from the :doc:`FormType </reference/forms/types/form>`:
3535

3636
.. include:: /reference/forms/types/options/empty_data_declaration.rst.inc
3737

38-
The default value is ``''`` (the empty string).
38+
From an HTTP perspective, submitted data is always a string or an array of strings.
39+
So by default, the form will treat any empty string as null. If you prefer to get
40+
an empty string, explicitly set the ``empty_data`` option to an empty string.
3941

4042
.. include:: /reference/forms/types/options/empty_data_description.rst.inc
4143

0 commit comments

Comments
 (0)
0