diff --git a/packages/node_modules/@node-red/editor-client/src/js/nodes.js b/packages/node_modules/@node-red/editor-client/src/js/nodes.js index 78b9deae6..ab7fae401 100644 --- a/packages/node_modules/@node-red/editor-client/src/js/nodes.js +++ b/packages/node_modules/@node-red/editor-client/src/js/nodes.js @@ -600,6 +600,14 @@ RED.nodes = (function() { RED.events.emit('nodes:add',n); } function addLink(l) { + if (nodeLinks[l.source.id]) { + const isUnique = nodeLinks[l.source.id].out.every(function(link) { + return link.sourcePort !== l.sourcePort || link.target.id !== l.target.id + }) + if (!isUnique) { + return + } + } links.push(l); if (l.source) { // Possible the node hasn't been added yet