From 43c5aabda523088f2a7daadfba2d378de46f5d7f Mon Sep 17 00:00:00 2001 From: uwetews Date: Wed, 9 Mar 2016 03:13:15 +0100 Subject: [PATCH] update {capture} compiler tag nesting code --- libs/sysplugins/smarty_internal_compile_capture.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/libs/sysplugins/smarty_internal_compile_capture.php b/libs/sysplugins/smarty_internal_compile_capture.php index bea31514..3791ab36 100644 --- a/libs/sysplugins/smarty_internal_compile_capture.php +++ b/libs/sysplugins/smarty_internal_compile_capture.php @@ -49,7 +49,7 @@ class Smarty_Internal_Compile_Capture extends Smarty_Internal_CompileBase $assign = isset($_attr[ 'assign' ]) ? $_attr[ 'assign' ] : 'null'; $append = isset($_attr[ 'append' ]) ? $_attr[ 'append' ] : 'null'; - $compiler->_capture_stack[ 0 ][] = array($buffer, $assign, $append, $compiler->nocache); + $this->openTag($compiler, 'capture', array($buffer, $assign, $append, $compiler->nocache)); // maybe nocache because of nocache variables $compiler->nocache = $compiler->nocache | $compiler->tag_nocache; $_output = @@ -103,8 +103,7 @@ class Smarty_Internal_Compile_CaptureClose extends Smarty_Internal_CompileBase if ($compiler->nocache) { $compiler->tag_nocache = true; } - - list($buffer, $assign, $append, $compiler->nocache) = array_pop($compiler->_capture_stack[ 0 ]); + list($buffer, $assign, $append, $compiler->nocache) = $this->closeTag($compiler, array('capture')); $_output = "smarty->_cache['capture_stack']);\n";