mirror of
https://github.com/twigphp/Twig.git
synced 2026-09-15 20:06:31 +00:00
Making a capturing group non capturing, as the group isn't used.
This commit is contained in:
+1
-1
@@ -179,7 +179,7 @@ class Twig_Lexer implements Twig_LexerInterface
|
||||
$trimTag = preg_quote($this->options['whitespace_trim'] . $this->options['tag_block'][1], '/');
|
||||
$endTag = preg_quote($this->options['tag_block'][1], '/');
|
||||
|
||||
if (empty($this->brackets) && preg_match('/\s*(' . $trimTag . '\h*|\s*' . $endTag . ')\n?/A', $this->code, $match, null, $this->cursor)) {
|
||||
if (empty($this->brackets) && preg_match('/\s*(?:' . $trimTag . '\h*|\s*' . $endTag . ')\n?/A', $this->code, $match, null, $this->cursor)) {
|
||||
$this->pushToken(Twig_Token::BLOCK_END_TYPE);
|
||||
$this->moveCursor($match[0]);
|
||||
$this->state = self::STATE_DATA;
|
||||
|
||||
Reference in New Issue
Block a user