Commit 5fb46a1
committed
minor #19328 Fix code example: replace request get() with all() method to support non-scalar types (alejgarciarodriguez)
This PR was merged into the 5.4 branch.
Discussion
----------
Fix code example: replace request get() with all() method to support non-scalar types
<!--
If your pull request fixes a BUG, use the oldest maintained branch that contains
the bug (see https://symfony.com/releases for the list of maintained branches).
If your pull request documents a NEW FEATURE, use the same Symfony branch where
the feature was introduced (and `6.x` for features of unreleased versions).
-->
Method `$request->request->get` does not support non-scalar types so it won't work with forms since they are received as an array type.
Using `get` used to work in older Symfony versions but no longer does, now an exception is thrown.
IMO we should use `all` method instead in this example.
Commits
-------
3a0df2b replace get() with all() method to support non-scalar types1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
20 | | - | |
| 20 | + | |
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| |||
0 commit comments