From 97f91156de874e01d0b5ede9cfe6b985e96a8a35 Mon Sep 17 00:00:00 2001 From: Benjamin Renard Date: Fri, 3 Mar 2023 10:34:17 +0100 Subject: [PATCH] Config::set(): fix setting value in inexisting section --- src/Config.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Config.php b/src/Config.php index eaa203b..b42abb2 100644 --- a/src/Config.php +++ b/src/Config.php @@ -224,7 +224,7 @@ Class Config { } for ($i=0; $i < count($exploded_key) - 1; $i++) { $k = $exploded_key[$i]; - if (!array_key_exists($k, $config)) + if (!array_key_exists($k, $parent)) $parent[$k] = array(); $parent = &$parent[$k]; }