bugfix fetch('extends:foo.tpl') always yielded $source->exists == true (Forum Topic 20980)

This commit is contained in:
rodneyrehm
2012-02-06 20:18:47 +00:00
parent 8f805ca871
commit 6d90cd3fd7
2 changed files with 3 additions and 2 deletions

View File

@@ -1,6 +1,7 @@
===== trunk ===== ===== trunk =====
06.02.2012 06.02.2012
- improvement stream_resolve_include_path() added to Smarty_Internal_Get_Include_Path (Forum Topic 20980) - improvement stream_resolve_include_path() added to Smarty_Internal_Get_Include_Path (Forum Topic 20980)
- bugfix fetch('extends:foo.tpl') always yielded $source->exists == true (Forum Topic 20980)
30.01.2012 30.01.2012
- bugfix Smarty_Security internal $_resource_dir cache wasn't properly propagated - bugfix Smarty_Security internal $_resource_dir cache wasn't properly propagated

View File

@@ -45,7 +45,7 @@ class Smarty_Internal_Resource_Extends extends Smarty_Resource {
$sources[$s->uid] = $s; $sources[$s->uid] = $s;
$uid .= $s->filepath; $uid .= $s->filepath;
if ($_template && $_template->smarty->compile_check) { if ($_template && $_template->smarty->compile_check) {
$exists == $exists && $s->exists; $exists = $exists && $s->exists;
} }
} }
$source->components = $sources; $source->components = $sources;
@@ -68,7 +68,7 @@ class Smarty_Internal_Resource_Extends extends Smarty_Resource {
{ {
$source->exists = true; $source->exists = true;
foreach ($source->components as $s) { foreach ($source->components as $s) {
$source->exists == $source->exists && $s->exists; $source->exists = $source->exists && $s->exists;
} }
$source->timestamp = $s->timestamp; $source->timestamp = $s->timestamp;
} }