- bugfix possible warning "attempt to modify property of non-object" in {section} (issue #34)

This commit is contained in:
rodneyrehm
2011-09-27 10:09:25 +00:00
parent 709e5e1e84
commit b6e6b67548
2 changed files with 4 additions and 1 deletions

View File

@@ -1,4 +1,7 @@
===== trunk =====
27.09.2011
- bugfix possible warning "attempt to modify property of non-object" in {section} (issue #34)
26.09.2011
- bugfix repeated calls to same subtemplate did not make use of cached template object

View File

@@ -59,7 +59,7 @@ class Smarty_Internal_Compile_Section extends Smarty_Internal_CompileBase {
$section_name = $_attr['name'];
$output .= "unset(\$_smarty_tpl->tpl_vars['smarty']->value['section'][$section_name]);\n";
$output .= "if (isset(\$_smarty_tpl->tpl_vars['smarty']->value['section'][$section_name])) unset(\$_smarty_tpl->tpl_vars['smarty']->value['section'][$section_name]);\n";
$section_props = "\$_smarty_tpl->tpl_vars['smarty']->value['section'][$section_name]";
foreach ($_attr as $attr_name => $attr_value) {