diff --git a/cache/classes/config.php b/cache/classes/config.php index 5fdf2b95cd36e..53d0f1e178e30 100644 --- a/cache/classes/config.php +++ b/cache/classes/config.php @@ -330,7 +330,11 @@ protected function include_configuration() { if (!file_exists($cachefile)) { throw new cache_exception('Default cache config could not be found. It should have already been created by now.'); } - include($cachefile); + + if (!include($cachefile)) { + throw new cache_exception('Unable to load the cache configuration file'); + } + if (!is_array($configuration)) { throw new cache_exception('Invalid cache configuration file'); }