summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--inc/template.php2
-rw-r--r--install.php2
2 files changed, 2 insertions, 2 deletions
diff --git a/inc/template.php b/inc/template.php
index c10ac454..48b2b1bb 100644
--- a/inc/template.php
+++ b/inc/template.php
@@ -23,7 +23,7 @@ function load_twig() {
$loader->setPaths($config['dir']['template']);
$twig = new Twig_Environment($loader, array(
'autoescape' => false,
- 'cache' => is_writable('templates') && (!is_dir('templates/cache') || is_writable('templates/cache')) ?
+ 'cache' => is_writable('templates') || (is_dir('templates/cache') && is_writable('templates/cache')) ?
"{$config['dir']['template']}/cache" : false,
'debug' => $config['debug']
));
diff --git a/install.php b/install.php
index db2e7885..d5ccc7c5 100644
--- a/install.php
+++ b/install.php
@@ -721,7 +721,7 @@ if ($step == 0) {
array(
'category' => 'File permissions',
'name' => getcwd() . '/templates/cache',
- 'result' => is_writable('templates') && (!is_dir('templates/cache') || is_writable('templates/cache')),
+ 'result' => is_writable('templates') || (is_dir('templates/cache') && is_writable('templates/cache')),
'required' => true,
'message' => 'You must give vichan permission to create (and write to) the <code>templates/cache</code> directory or performance will be drastically reduced.'
),