We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a68e1ad + d5bb7c3 commit d518544Copy full SHA for d518544
src/Symfony/Component/Form/ChoiceList/ArrayChoiceList.php
@@ -105,7 +105,7 @@ public function getChoicesForValues(array $values): array
105
$choices = [];
106
107
foreach ($values as $i => $givenValue) {
108
- if (\array_key_exists($givenValue, $this->choices)) {
+ if (\array_key_exists($givenValue ?? '', $this->choices)) {
109
$choices[$i] = $this->choices[$givenValue];
110
}
111
0 commit comments