Skip to content

Commit

Permalink
fix compilation for caching templates (#801)
Browse files Browse the repository at this point in the history
  • Loading branch information
Storyxx authored Sep 18, 2022
1 parent d683641 commit db80246
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libs/sysplugins/smarty_internal_template.php
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ public function _subTemplateRender(
$smarty = &$this->smarty;
$_templateId = $smarty->_getTemplateId($template, $cache_id, $compile_id, $caching, $tpl);
// recursive call ?
if (isset($tpl->templateId) ? $tpl->templateId : $tpl->_getTemplateId() !== $_templateId) {
if ((isset($tpl->templateId) ? $tpl->templateId : $tpl->_getTemplateId()) !== $_templateId) {
// already in template cache?
if (isset(self::$tplObjCache[ $_templateId ])) {
// copy data from cached object
Expand Down Expand Up @@ -358,7 +358,7 @@ public function _subTemplateRender(
}
if ($tpl->caching === 9999) {
if (!isset($tpl->compiled)) {
$this->loadCompiled(true);
$tpl->loadCompiled(true);
}
if ($tpl->compiled->has_nocache_code) {
$this->cached->hashes[ $tpl->compiled->nocache_hash ] = true;
Expand Down

0 comments on commit db80246

Please sign in to comment.