fix: Don't throw error on expressions referring to nodes that don't exist in the workflow (#5155)

This commit is contained in:
कारतोफ्फेलस्क्रिप्ट™ 2023-01-13 15:14:03 +01:00 committed by GitHub
parent d10ca530cf
commit b7faf4a0df
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -575,13 +575,14 @@ export class WorkflowDataProxy {
get(target, name, receiver) {
const nodeName = name.toString();
if (that.workflow.getNode(nodeName) === null) {
throw new ExpressionError(`"${nodeName}" node doesn't exist`, {
runIndex: that.runIndex,
itemIndex: that.itemIndex,
failExecution: true,
});
}
// TODO: re-enable this for v1.0.0 release
// if (that.workflow.getNode(nodeName) === null) {
// throw new ExpressionError(`"${nodeName}" node doesn't exist`, {
// runIndex: that.runIndex,
// itemIndex: that.itemIndex,
// failExecution: true,
// });
// }
return that.nodeDataGetter(nodeName);
},