summaryrefslogtreecommitdiffstats
path: root/lib/SimpleSAML/XHTML
diff options
context:
space:
mode:
authorJaime Perez Crespo <jaime.perez@uninett.no>2016-02-29 16:11:48 +0100
committerJaime Perez Crespo <jaime.perez@uninett.no>2016-02-29 16:11:48 +0100
commit8af147c8d4fa9384b2959bd6aee30ca593cd0442 (patch)
treeaeb184cc50e69e6d57abf6fbaf46f3e6dc5a9055 /lib/SimpleSAML/XHTML
parentf66612385c58e18dfb86478ecd5698ab41af363a (diff)
downloadsimplesamlphp-8af147c8d4fa9384b2959bd6aee30ca593cd0442.zip
simplesamlphp-8af147c8d4fa9384b2959bd6aee30ca593cd0442.tar.gz
simplesamlphp-8af147c8d4fa9384b2959bd6aee30ca593cd0442.tar.bz2
Add a couple of configuration options to handle template caching.
Diffstat (limited to 'lib/SimpleSAML/XHTML')
-rw-r--r--lib/SimpleSAML/XHTML/Template.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/SimpleSAML/XHTML/Template.php b/lib/SimpleSAML/XHTML/Template.php
index 47b5586..4c3ea3d 100644
--- a/lib/SimpleSAML/XHTML/Template.php
+++ b/lib/SimpleSAML/XHTML/Template.php
@@ -96,12 +96,12 @@ class SimpleSAML_XHTML_Template
*/
private function setupTwig()
{
- // TODO: Get cache-location from config
- $cache = $this->configuration->resolvePath('cache');
+ $cache = $this->configuration->getString('template.cache', $this->configuration->resolvePath('cache'));
// check if template exists
$loader = $this->setupTwigTemplatepaths();
if (!$loader) { return false; }
- $auto_reload = true; // TODO: set this in config
+
+ $auto_reload = $this->configuration->getBoolean('template.auto_reload', false);
$this->twig = new \Twig_Environment($loader, array('cache' => $cache, 'auto_reload' => $auto_reload));
return true;
}