aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/smarty/smarty/lexer/smarty_internal_templateparser.y
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/smarty/smarty/lexer/smarty_internal_templateparser.y')
-rw-r--r--vendor/smarty/smarty/lexer/smarty_internal_templateparser.y10
1 files changed, 8 insertions, 2 deletions
diff --git a/vendor/smarty/smarty/lexer/smarty_internal_templateparser.y b/vendor/smarty/smarty/lexer/smarty_internal_templateparser.y
index b8c00e5d9..c6890642f 100644
--- a/vendor/smarty/smarty/lexer/smarty_internal_templateparser.y
+++ b/vendor/smarty/smarty/lexer/smarty_internal_templateparser.y
@@ -249,7 +249,13 @@ template ::= template PHP(B). {
// template text
template ::= template TEXT(B). {
- $this->current_buffer->append_subtree($this, $this->compiler->processText(B));
+ $text = $this->yystack[ $this->yyidx + 0 ]->minor;
+
+ if ((string)$text == '') {
+ $this->current_buffer->append_subtree($this, null);
+ }
+
+ $this->current_buffer->append_subtree($this, new Smarty_Internal_ParseTree_Text($text, $this->strip));
}
// strip on
template ::= template STRIPON. {
@@ -308,7 +314,7 @@ smartytag(A)::= SIMPLETAG(B). {
$tag = trim(substr(B, $this->compiler->getLdelLength(), -$this->compiler->getRdelLength()));
if ($tag == 'strip') {
$this->strip = true;
- A = null;;
+ A = null;
} else {
if (defined($tag)) {
if ($this->security) {