diff --git a/lib/Alchemy/Phrasea/Core/Configuration/RegistryFormManipulator.php b/lib/Alchemy/Phrasea/Core/Configuration/RegistryFormManipulator.php index d2162af960..04b24b2d2f 100644 --- a/lib/Alchemy/Phrasea/Core/Configuration/RegistryFormManipulator.php +++ b/lib/Alchemy/Phrasea/Core/Configuration/RegistryFormManipulator.php @@ -188,12 +188,14 @@ public function getRegistryData(FormInterface $form = null, PropertyAccess $conf private function filterNullValues(array &$array) { - return array_filter($array, function (&$value) { + foreach ($array as $key => &$value) { if (is_array($value)) { - $value = $this->filterNullValues($value); + $this->filterNullValues($value); } - - return null !== $value; - }); + else if ($key !== 'geonames-server' && $value === null) { + unset($array[$key]); + } + } + return $array; } }