Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Runtime: Modulo throwing DivisionByZeroError #6363

Merged
merged 1 commit into from
Jul 21, 2022
Merged

Runtime: Modulo throwing DivisionByZeroError #6363

merged 1 commit into from
Jul 21, 2022

Conversation

JohnathonKoster
Copy link
Contributor

This PR fixes #6360 by correctly grouping the % operator with its operands.

The following will now work as expected without explicitly adding ():

{{ if 6 % 2 == 0 }} ... {{ /if }}

The provided test case will also fail when moved to the base branch.

@jasonvarga
Copy link
Member

Legend

@jasonvarga jasonvarga merged commit a96b3bb into statamic:3.3 Jul 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Modulo throwing DivisionByZeroError (Modulo by Zero) in new Antlers Parser
2 participants