mirror of
https://github.com/Shopify/liquid.git
synced 2026-09-19 10:52:48 -07:00
Use safe_parse_expression instead of parse_expression
This commit is contained in:
committed by
Guilherme Carreiro
parent
d77662cd0e
commit
4f7dafbcac
@@ -68,8 +68,7 @@ module Liquid
|
|||||||
|
|
||||||
raise SyntaxError, options[:locale].t("errors.syntax.cycle") if p.look(:end_of_string)
|
raise SyntaxError, options[:locale].t("errors.syntax.cycle") if p.look(:end_of_string)
|
||||||
|
|
||||||
while (var = p.expression)
|
while (var = safe_parse_expression(p))
|
||||||
var = parse_expression(var)
|
|
||||||
@variables << var
|
@variables << var
|
||||||
break unless p.consume?(:comma)
|
break unless p.consume?(:comma)
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user