Skip to content

Commit ec0b7cf

Browse files
committed
1570 SF
1 parent 7fe0b47 commit ec0b7cf

File tree

1 file changed

+4
-3
lines changed
  • server/libs/ai/mcp/mcp-tool/mcp-tool-platform/src/main/java/com/bytechef/ai/mcp/tool/platform

1 file changed

+4
-3
lines changed

server/libs/ai/mcp/mcp-tool/mcp-tool-platform/src/main/java/com/bytechef/ai/mcp/tool/platform/ComponentTools.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -538,16 +538,17 @@ public PropertyInfo getOutputProperty(
538538
outputResponse = actionDefinition.getOutputResponse();
539539
} else if (actionDefinition.isOutputFunctionDefined()) {
540540
try {
541-
542541
outputResponse = actionDefinitionFacade.executeOutput(
543542
componentDefinition.getName(), componentDefinition.getVersion(),
544543
actionDefinition.getName(), Map.of(), Map.of());
545544
} catch (Exception e) {
546545
try {
547546
List<Connection> connections =
548547
connectionService.getConnections(componentName, version, ModeType.AUTOMATION);
549-
Map<String, Long> connectionIds = Map.of(operationName, connections.get(0)
550-
.getId());
548+
549+
Connection connection = connections.getFirst();
550+
551+
Map<String, Long> connectionIds = Map.of(operationName, connection.getId());
551552

552553
var output = actionDefinitionFacade.executePerform(componentDefinition.getName(),
553554
componentDefinition.getVersion(), actionDefinition.getName(), null, null, null,

0 commit comments

Comments
 (0)