fix: Use correct node version when pasting/importing nodes (#8456)

Co-authored-by: Michael Kret <michael.k@radency.com>
This commit is contained in:
Elias Meire
2024-01-26 15:09:50 +01:00
committed by GitHub
parent 8a595d1527
commit 70af67e744
4 changed files with 135 additions and 47 deletions

View File

@@ -184,7 +184,7 @@ export function generateNodesGraph(
webhookNodeNames.push(node.name);
} else {
try {
const nodeType = nodeTypes.getByNameAndVersion(node.type);
const nodeType = nodeTypes.getByNameAndVersion(node.type, node.typeVersion);
if (nodeType) {
const nodeParameters = getNodeParameters(
nodeType.description.properties,
@@ -230,7 +230,7 @@ export function generateNodesGraph(
Object.keys(connections).forEach((key) => {
connections[key].forEach((element) => {
element.forEach((element2) => {
(element ?? []).forEach((element2) => {
nodeGraph.node_connections.push(getGraphConnectionItem(nodeName, element2));
});
});