Skip to content

Including templates with blocks containing parameters lacking default values panics #85

Description

@mvrhov

The engine crashes with the following error:
"panic: runtime error: invalid memory address or nil pointer dereference"

Reporducer:

Main template

{{block body()}}
{{include "include.jet"}}
{{end}}

include.jet

{{block inputField(label)}}
{{label}}
{{end}}

the problem seems to be that the label doesn't have default value... If {{block inputField(label)}} is changed to {{block inputField(label="foo")}} then there is no crash

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions