Radu Cotescu created SLING-9696: ----------------------------------- Summary: HTL does not correctly cast the "false" string to Boolean Key: SLING-9696 URL: https://issues.apache.org/jira/browse/SLING-9696 Project: Sling Issue Type: Bug Components: Scripting Affects Versions: Scripting HTL Engine 1.4.0-1.4.0, Scripting HTL Engine 1.3.0-1.4.0, Scripting HTL Engine 1.2.0-1.4.0, Scripting HTL Engine 1.1.0-1.4.0, Scripting HTL Engine 1.0.20, Scripting Sightly Engine 1.0.0 Reporter: Radu Cotescu Assignee: Radu Cotescu Fix For: Scripting HTL Engine 1.4.4-1.4.0
The HTL engine implementation from Apache Sling seems to have never correctly casted the "false" string to boolean. The HTL specification [0] mentions the following: {noformat} These expressions evaluate to false: * false * 0 (zero) * '' or "" (empty string) * [] (empty iterable) These evaluate to true: * "false" (non-empty string) * [0] (non-empty iterable) {noformat} [0] - https://github.com/adobe/htl-spec/blob/1.4/SPECIFICATION.md#115-casting -- This message was sent by Atlassian Jira (v8.3.4#803005)