From ebdc48d54d82b74230a8aed6458c238ec5788e38 Mon Sep 17 00:00:00 2001 From: Nicolas Grekas Date: Mon, 17 Apr 2023 17:04:56 +0200 Subject: [PATCH] [Form] fix merge --- ChoiceList/Loader/AbstractChoiceLoader.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ChoiceList/Loader/AbstractChoiceLoader.php b/ChoiceList/Loader/AbstractChoiceLoader.php index 1eae069b2..0f6a64dd3 100644 --- a/ChoiceList/Loader/AbstractChoiceLoader.php +++ b/ChoiceList/Loader/AbstractChoiceLoader.php @@ -59,7 +59,7 @@ public function loadValuesForChoices(array $choices, callable $value = null) if ($value) { // if a value callback exists, use it - return array_map(function ($item) use ($value): string { return $value($item); }, $choices); + return array_map(function ($item) use ($value) { return (string) $value($item); }, $choices); } return $this->doLoadValuesForChoices($choices);