mirror of
https://github.com/Mibew/handlebars.php.git
synced 2024-11-15 08:44:12 +03:00
make sure that buffer is always a string
This commit is contained in:
parent
35ea671fd7
commit
07c49bbb3f
@ -100,7 +100,7 @@ class Tokenizer
|
||||
protected $state;
|
||||
protected $tagType;
|
||||
protected $tag;
|
||||
protected $buffer;
|
||||
protected $buffer = '';
|
||||
protected $tokens;
|
||||
protected $seenTag;
|
||||
protected $lineStart;
|
||||
@ -294,7 +294,7 @@ class Tokenizer
|
||||
*/
|
||||
protected function flushBuffer()
|
||||
{
|
||||
if (!empty($this->buffer) or $this->buffer === '0') {
|
||||
if ($this->buffer !== '') {
|
||||
$this->tokens[] = array(
|
||||
self::TYPE => self::T_TEXT,
|
||||
self::VALUE => $this->buffer
|
||||
|
Loading…
Reference in New Issue
Block a user