diff --git a/modules/cms/classes/Theme.php b/modules/cms/classes/Theme.php index ca97b1100..0086ecc99 100644 --- a/modules/cms/classes/Theme.php +++ b/modules/cms/classes/Theme.php @@ -50,7 +50,6 @@ class Theme const ACTIVE_KEY = 'cms::theme.active'; const EDIT_KEY = 'cms::theme.edit'; - const CONFIG_KEY = 'cms::theme.config'; /** * Loads the theme. @@ -341,21 +340,7 @@ class Theme return $this->configCache = []; } - try { - if (Config::get('app.debug', false)) { - $config = Yaml::parseFile($path); - } else { - $cacheKey = self::CONFIG_KEY.'::'.$this->getDirName(); - $config = Cache::rememberForever($cacheKey, function () use ($path) { - return Yaml::parseFile($path); - }); - } - } - catch (Exception $ex) { - // Cache failed - $config = Yaml::parseFile($path); - } - + $config = Yaml::parseFile($path); /** * @event cms.theme.extendConfig @@ -505,7 +490,6 @@ class Theme Cache::forget(self::ACTIVE_KEY); Cache::forget(self::EDIT_KEY); - Cache::forget(self::CONFIG_KEY.'::'.(new self)->getDirName()); } /** diff --git a/modules/system/traits/ConfigMaker.php b/modules/system/traits/ConfigMaker.php index 92245ab83..9a78be8c3 100644 --- a/modules/system/traits/ConfigMaker.php +++ b/modules/system/traits/ConfigMaker.php @@ -65,7 +65,7 @@ trait ConfigMaker )); } - $config = Yaml::parse(File::get($configFile)); + $config = Yaml::parseFile($configFile); /* * Extensibility