- bugfix on caching mode SMARTY_CACHING_LIFETIME_SAVED and cache_lifetime = 0

This commit is contained in:
Uwe.Tews
2010-03-23 17:08:46 +00:00
parent 2e27c294b3
commit 63d671b935
2 changed files with 3 additions and 2 deletions

View File

@@ -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()

View File

@@ -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 {
}
?>
?>