mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
catch node extended
This commit is contained in:
@@ -734,11 +734,17 @@ class Flow {
|
||||
} else {
|
||||
var handledByUncaught = false;
|
||||
|
||||
const flow = this;
|
||||
this.catchNodes.forEach(function(targetCatchNode) {
|
||||
if (targetCatchNode.scope && targetCatchNode.scope.indexOf(reportingNode.id) === -1) {
|
||||
if (Array.isArray(targetCatchNode.scope) && targetCatchNode.scope.indexOf(reportingNode.id) === -1) {
|
||||
return;
|
||||
}
|
||||
if (!targetCatchNode.scope && targetCatchNode.uncaught && !handledByUncaught) {
|
||||
|
||||
if (targetCatchNode.scope === "group" && flow.isNodeInSameGroup(targetCatchNode, reportingNode) === false){
|
||||
return;
|
||||
}
|
||||
|
||||
if ((!targetCatchNode.scope || targetCatchNode.scope === "group") && targetCatchNode.uncaught && !handledByUncaught) {
|
||||
if (handled) {
|
||||
// This has been handled by a !uncaught catch node
|
||||
return;
|
||||
|
Reference in New Issue
Block a user