From a9e192d6b19985869ac3677a2380718cebd22092 Mon Sep 17 00:00:00 2001 From: Awilum Date: Wed, 19 Dec 2018 19:48:34 +0300 Subject: [PATCH] Flextype fallback settings implementation - use array_replace_recursive() instead of array_merge --- flextype/Flextype.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/flextype/Flextype.php b/flextype/Flextype.php index 8f2fccd7..f93e9274 100755 --- a/flextype/Flextype.php +++ b/flextype/Flextype.php @@ -152,14 +152,13 @@ class Flextype $site_settings = YamlParser::decode(Filesystem::getFileContent($site_settings_file_path)); // Merge settings - $settings = array_merge($default_settings, $site_settings); + $settings = array_replace_recursive($default_settings, $site_settings); // Set settings Registry::set('settings', $settings); } else { throw new \RuntimeException("Flextype settings and Site settings config files does not exist."); } - } /**