Handle parsing number into boolean expression

This commit is contained in:
nathan 2023-07-06 08:29:30 -06:00
parent d65e0d1e1e
commit 2d0976f456

View File

@ -351,11 +351,16 @@ export class et2_arrayMgr
parseBoolExpression(_expression : string)
{
if (typeof _expression === "undefined" || _expression === null)
if(typeof _expression === "undefined" || _expression === null)
{
return false;
}
if(typeof _expression === "number")
{
return !!_expression;
}
// Check whether "$" occurs in the given identifier, don't parse rows if we're not in a row
// This saves booleans in repeating rows from being parsed too early - we'll parse again when repeating
if(_expression.indexOf('$') >= 0 && this.perspectiveData.row == null && _expression.match(/\$\{?row\}?/))