(a, b)
| 368 | // azureChatOpenAI_0-output-azureChatOpenAI-A|B|C vs azureChatOpenAI_0-output-azureChatOpenAI-A|B |
| 369 | // We compare by stripping the last "-..." segment if it contains pipes. |
| 370 | const handlesEqual = (a, b) => { |
| 371 | if (a === b) return true |
| 372 | const stripPipeSuffix = (s) => { |
| 373 | if (!s) return s |
| 374 | const lastDash = s.lastIndexOf('-') |
| 375 | if (lastDash === -1) return s |
| 376 | const suffix = s.substring(lastDash + 1) |
| 377 | return suffix.includes('|') ? s.substring(0, lastDash) : s |
| 378 | } |
| 379 | return stripPipeSuffix(a) === stripPipeSuffix(b) |
| 380 | } |
| 381 | |
| 382 | for (const edge of edges) { |
| 383 | const targetNodeId = edge.targetHandle.split('-')[0] |
no test coverage detected