Skip to content

Commit 360711c

Browse files
vudaltsovnicolas-grekas
authored andcommitted
[Form] Fix inconsistencies
1 parent 926246b commit 360711c

File tree

3 files changed

+13
-17
lines changed

3 files changed

+13
-17
lines changed

src/Symfony/Component/Form/ChoiceList/ArrayChoiceList.php

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -172,13 +172,13 @@ public function getValuesForChoices(array $choices)
172172
/**
173173
* Flattens an array into the given output variables.
174174
*
175-
* @param array $choices The array to flatten
176-
* @param callable $value The callable for generating choice values
177-
* @param array $choicesByValues The flattened choices indexed by the
178-
* corresponding values
179-
* @param array $keysByValues The original keys indexed by the
180-
* corresponding values
181-
* @param array $structuredValues The values indexed by the original keys
175+
* @param array $choices The array to flatten
176+
* @param callable $value The callable for generating choice values
177+
* @param array|null $choicesByValues The flattened choices indexed by the
178+
* corresponding values
179+
* @param array|null $keysByValues The original keys indexed by the
180+
* corresponding values
181+
* @param array|null $structuredValues The values indexed by the original keys
182182
*
183183
* @internal
184184
*/

src/Symfony/Component/Form/ChoiceList/Factory/ChoiceListFactoryInterface.php

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,7 @@ interface ChoiceListFactoryInterface
3232
* Null may be passed when the choice list contains the empty value.
3333
*
3434
* @param iterable $choices The choices
35-
* @param callable|null $value The callable generating the choice
36-
* values
35+
* @param callable|null $value The callable generating the choice values
3736
*
3837
* @return ChoiceListInterface The choice list
3938
*/
@@ -46,9 +45,7 @@ public function createListFromChoices($choices, $value = null);
4645
* The callable receives the choice as only argument.
4746
* Null may be passed when the choice list contains the empty value.
4847
*
49-
* @param ChoiceLoaderInterface $loader The choice loader
50-
* @param callable|null $value The callable generating the choice
51-
* values
48+
* @param callable|null $value The callable generating the choice values
5249
*
5350
* @return ChoiceListInterface The choice list
5451
*/
@@ -80,7 +77,6 @@ public function createListFromLoader(ChoiceLoaderInterface $loader, $value = nul
8077
* match the keys of the choices. The values should be arrays of HTML
8178
* attributes that should be added to the respective choice.
8279
*
83-
* @param ChoiceListInterface $list The choice list
8480
* @param array|callable|null $preferredChoices The preferred choices
8581
* @param callable|null $label The callable generating the
8682
* choice labels

src/Symfony/Component/Form/ChoiceList/View/ChoiceView.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,10 @@ class ChoiceView
3030
/**
3131
* Creates a new choice view.
3232
*
33-
* @param mixed $data The original choice
34-
* @param string $value The view representation of the choice
35-
* @param string $label The label displayed to humans
36-
* @param array $attr Additional attributes for the HTML tag
33+
* @param mixed $data The original choice
34+
* @param string $value The view representation of the choice
35+
* @param string|false $label The label displayed to humans; pass false to discard the label
36+
* @param array $attr Additional attributes for the HTML tag
3737
*/
3838
public function __construct($data, $value, $label, array $attr = [])
3939
{

0 commit comments

Comments
 (0)