protected function getPagesConfig() { if (self::$configCache !== false) { return self::$configCache; } $filePath = $this->getConfigFilePath(); if (!file_exists($filePath)) { return self::$configCache = ['static-pages' => []]; } $config = Yaml::parse(File::get($filePath)); if (!array_key_exists('static-pages', $config)) { throw new SystemException('The content of the theme meta/static-pages.yaml file is invalid: the "static-pages" root element is not found.'); } return self::$configCache = $config; }