Skip to content

Commit 70b388b

Browse files
author
dsharp
committed
ELSE expressions terminate early when encountering an END token
1 parent f440917 commit 70b388b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Parsers/Expressions.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ public static function parse(Parser $parser, TokensList $list, array $options =
185185
$isExpr = true;
186186
} elseif (
187187
$brackets === 0 && strlen((string) $ret->expr) > 0 && ! $alias
188-
&& ($ret->table === null || $ret->table === '')
188+
&& ($token->value === "END" || ($ret->table === null || $ret->table === ''))
189189
) {
190190
/* End of expression */
191191
break;

0 commit comments

Comments
 (0)