Skip to content

#if with empty body causes 'Sequence contains no elements' error #202

Closed

Description

@paulashton

The following template content results in a 'Sequence contains no elements' error when an attempt is made to compile it:

{{#if false}}
{{else}}
 
{{/if}}

If you add a blank line between the {{#if false}} and the {{else}} then it works fine.

[ The example above is not what I was actually trying to use. I was calling a helper and got the same error; the template above was a simple way of illustrating the problem. ]

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions