diff --git a/change_log.txt b/change_log.txt index c158c32b..530ff8b9 100644 --- a/change_log.txt +++ b/change_log.txt @@ -1,5 +1,6 @@ 23/03/2010 - bugfix on template inheritance when calling multiple child/parent relations +- bugfix on caching mode SMARTY_CACHING_LIFETIME_SAVED and cache_lifetime = 0 22/03/2010 - bugfix make directory separator operating system independend in compileAllTemplates() diff --git a/libs/sysplugins/smarty_internal_template.php b/libs/sysplugins/smarty_internal_template.php index b3597842..f48bf450 100644 --- a/libs/sysplugins/smarty_internal_template.php +++ b/libs/sysplugins/smarty_internal_template.php @@ -357,7 +357,7 @@ class Smarty_Internal_Template extends Smarty_Internal_Data { return $this->isCached; } $this->cacheFileChecked = true; - if ($this->caching === SMARTY_CACHING_LIFETIME_SAVED && $this->properties['cache_lifetime'] > 0 && (time() > ($this->getCachedTimestamp() + $this->properties['cache_lifetime']))) { + if ($this->caching === SMARTY_CACHING_LIFETIME_SAVED && $this->properties['cache_lifetime'] >= 0 && (time() > ($this->getCachedTimestamp() + $this->properties['cache_lifetime']))) { $this->rendered_content = null; return $this->isCached; } @@ -861,4 +861,4 @@ class Smarty_Internal_Template extends Smarty_Internal_Data { class Smarty_Template extends Smarty_Internal_Template { } -?> +?> \ No newline at end of file