mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 18:41:14 +00:00
fix(editor): Fix schema view showing incorrect data on loop node done branch (#15635)
This commit is contained in:
@@ -55,6 +55,7 @@ type Props = {
|
||||
connectionType?: NodeConnectionType;
|
||||
search?: string;
|
||||
compact?: boolean;
|
||||
outputIndex?: number;
|
||||
};
|
||||
|
||||
const props = withDefaults(defineProps<Props>(), {
|
||||
@@ -66,6 +67,7 @@ const props = withDefaults(defineProps<Props>(), {
|
||||
search: '',
|
||||
mappingEnabled: false,
|
||||
compact: false,
|
||||
outputIndex: undefined,
|
||||
});
|
||||
|
||||
const telemetry = useTelemetry();
|
||||
@@ -113,7 +115,14 @@ const getNodeSchema = async (fullNode: INodeUi, connectedNode: IConnectedNode) =
|
||||
runIndex: getLastRunIndexWithData(fullNode.name, outputIndex, props.connectionType),
|
||||
}))
|
||||
.filter(({ runIndex }) => runIndex !== -1);
|
||||
const nodeData = connectedOutputsWithData
|
||||
|
||||
// If outputIndex is specified, only use data from that specific output branch
|
||||
const filteredOutputsWithData =
|
||||
props.outputIndex !== undefined
|
||||
? connectedOutputsWithData.filter(({ outputIndex }) => outputIndex === props.outputIndex)
|
||||
: connectedOutputsWithData;
|
||||
|
||||
const nodeData = filteredOutputsWithData
|
||||
.map(({ outputIndex, runIndex }) =>
|
||||
getNodeInputData(fullNode, runIndex, outputIndex, props.paneType, props.connectionType),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user