fixed endless loop when blockquote had not empty line after

feature/tests
Michael Ochmann 3 years ago
parent 86c895b971
commit 559574b492
  1. 2
      src/Parser.php

@ -468,7 +468,7 @@ class Parser {
} }
$buffer = ""; $buffer = "";
$elm = $this->document->createElement("blockquote", $buffer); $elm = $this->document->createElement("blockquote", $buffer);
while (!($this->current()->type === TokenType::EOL && $this->next()->type !== TokenType::GT)) { while (!($this->current()->type === TokenType::EOF) && !($this->current()->type === TokenType::EOL && $this->next()->type !== TokenType::GT)) {
$gt = $this->consume(); $gt = $this->consume();
if ($this->current()->type === TokenType::EOL) { if ($this->current()->type === TokenType::EOL) {
$this->consume(); $this->consume();

Loading…
Cancel
Save