Skip to content

Commit

Permalink
- bugfix Error when using {include} within {capture} #100
Browse files Browse the repository at this point in the history
  • Loading branch information
uwetews committed Oct 25, 2015
1 parent 1a51c1c commit 42e7229
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion libs/sysplugins/smarty_template_resource_base.php
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,13 @@ public function getRenderedTemplateCode(Smarty_Internal_Template $_template, $un
//
// render compiled or saved template code
//
if (!isset($_template->_cache['capture_stack'])) {
$_template->_cache['capture_stack'] = array();
}
$_saved_capture_level = count($_template->_cache['capture_stack']);
$unifunc($_template);
// any unclosed {capture} tags ?
if (isset($_template->_cache['capture_stack'][0])) {
if ($_saved_capture_level != count($_template->_cache['capture_stack'])) {
$_template->capture_error();
}
if (isset($_template->smarty->security_policy)) {
Expand Down

0 comments on commit 42e7229

Please sign in to comment.