Load compiled object in template constructor so it will be cached.

This commit is contained in:
Simon Wisselink
2023-01-31 14:48:41 +01:00
parent 0b2eae3137
commit cd158566d0

View File

@@ -131,7 +131,8 @@ class Template extends TemplateBase {
// Template resource
$this->template_resource = $template_resource;
$this->setSource($_isConfig ? Config::load($this) : Source::load($this));
$this->source = $_isConfig ? Config::load($this) : Source::load($this);
$this->compiled = Compiled::load($this);
if ($smarty->security_policy) {
$smarty->security_policy->registerCallBacks($this);