diff --git a/src/Config/CloudDataConfig.php b/src/Config/CloudDataConfig.php index 4f0c5bdba..a5ae83707 100644 --- a/src/Config/CloudDataConfig.php +++ b/src/Config/CloudDataConfig.php @@ -67,7 +67,7 @@ public function getConfigTreeBuilder(): TreeBuilder ->end() ->validate() ->ifTrue(function ($config) { - return is_array($config['keys']) && !empty($config['keys']) && !array_key_exists($config['acli_key'], $config['keys']); + return !empty($config['acli_key']) && (!is_array($config['keys']) || empty($config['keys']) || !array_key_exists($config['acli_key'], $config['keys'])); }) ->thenInvalid('acli_key must exist in keys'); return $treeBuilder;