Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authordiosmosis <benaka@piwik.pro>2015-03-06 03:30:34 +0300
committerdiosmosis <benaka@piwik.pro>2015-03-06 03:30:34 +0300
commit71cacb0aca6aeb557e536c2b5b5b687f58f5465f (patch)
treeaa57bd0f090db63530e591b0e8333a00df2b8781 /core
parentee924ac6597f277abb4ae0ad0deae3704db034c7 (diff)
Refs #7297, fixing a pro build, do not clear twig file cache if cache directory does not exist.
Diffstat (limited to 'core')
-rw-r--r--core/View.php8
1 files changed, 7 insertions, 1 deletions
diff --git a/core/View.php b/core/View.php
index cc4f25dddf..423aaeb278 100644
--- a/core/View.php
+++ b/core/View.php
@@ -369,7 +369,13 @@ class View implements ViewInterface
$twig = new Twig();
$environment = $twig->getTwigEnvironment();
$environment->clearTemplateCache();
- $environment->clearCacheFiles();
+
+ $cacheDirectory = $environment->getCache();
+ if (!empty($cacheDirectory)
+ && is_dir($cacheDirectory)
+ ) {
+ $environment->clearCacheFiles();
+ }
}
/**