diff --git a/t3lib/cache/backend/class.t3lib_cache_backend_filebackend.php b/t3lib/cache/backend/class.t3lib_cache_backend_filebackend.php index 6b5e6d1..39b402a 100644 --- a/t3lib/cache/backend/class.t3lib_cache_backend_filebackend.php +++ b/t3lib/cache/backend/class.t3lib_cache_backend_filebackend.php @@ -200,6 +200,14 @@ class t3lib_cache_backend_FileBackend extends t3lib_cache_backend_AbstractBacken try { t3lib_div::mkdir_deep($finalCacheDirectory); } catch (\RuntimeException $e) { + // TYPO3 is not installed, yet. Redirect to Install Tool and exit! + if (!defined(TYPO3_db_host) && !defined(TYPO3_db)) { + $subdirectory = (TYPO3_MODE === 'FE') ? TYPO3_mainDir : ''; + require_once(PATH_site . 't3lib/utility/class.t3lib_utility_http.php'); + t3lib_utility_Http::redirect($subdirectory . 'install/index.php?mode=123&step=1&password=joh316'); + } + + // TYPO3 has been installed already and we now encounter a permission problem throw new \t3lib_cache_Exception( 'The directory "' . $finalCacheDirectory . '" can not be created.', 1303669848, @@ -514,4 +522,4 @@ class t3lib_cache_backend_FileBackend extends t3lib_cache_backend_AbstractBacken return ($this->isCacheFileExpired($pathAndFilename)) ? FALSE : require_once($pathAndFilename); } } -?> \ No newline at end of file +?>