Skip to content

Twig variable parsing has issue. Can't assume "name" attribute exists for every node/expression #315

@DiegoPino

Description

@DiegoPino

What?

There are many Twig compiler expressions that don't have certain properties. I already found a few (e.g Binary Operators). Checking on each class type makes no sense and getting a name attribute when non-existent throws an exception. The proper way is to use the method twig provides to see if a property exist. @aksm pulling code now and merging in a few bc this blocks any template that uses binary operators (and many other I have never used).

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions