| 4839 | } |
| 4840 | // override to handle promise-compatible and/or short-circuiting |
| 4841 | evaluate(context) { |
| 4842 | var self2 = this; |
| 4843 | var shortCircuitValue = this.operator === "or"; |
| 4844 | var lhsVal = this.lhs.evaluate(context); |
| 4845 | var continueWith = function(resolvedLhs) { |
| 4846 | if (!!resolvedLhs === shortCircuitValue) { |
| 4847 | return resolvedLhs; |
| 4848 | } |
| 4849 | var rhsVal = self2.rhs.evaluate(context); |
| 4850 | if (rhsVal && rhsVal.then) { |
| 4851 | return rhsVal.then((r) => self2.resolve(context, { lhs: resolvedLhs, rhs: r })); |
| 4852 | } |
| 4853 | return self2.resolve(context, { lhs: resolvedLhs, rhs: rhsVal }); |
| 4854 | }; |
| 4855 | if (lhsVal && lhsVal.then) { |
| 4856 | return lhsVal.then(continueWith); |
| 4857 | } |
| 4858 | return continueWith(lhsVal); |
| 4859 | } |
| 4860 | }; |
| 4861 | var DotOrColonPathNode = class extends Expression { |
| 4862 | constructor(path, separator) { |