From 8165e385cf4ee06946e37ff74fad1e27b04f9939 Mon Sep 17 00:00:00 2001 From: amhsirak Date: Tue, 18 Mar 2025 23:45:21 +0530 Subject: [PATCH] feat: get last pair & target url --- src/components/robot/RobotEdit.tsx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/components/robot/RobotEdit.tsx b/src/components/robot/RobotEdit.tsx index f7e5fdfe..e56d9cf8 100644 --- a/src/components/robot/RobotEdit.tsx +++ b/src/components/robot/RobotEdit.tsx @@ -408,6 +408,9 @@ export const RobotEditModal = ({ isOpen, handleStart, handleClose, initialSettin return acc; }, {} as Record); + const lastPair = robot.recording.workflow[robot.recording.workflow.length - 1]; + const targetUrl = lastPair?.what.find(action => action.action === "goto")?.args?.[0]; + const payload = { name: robot.recording_meta.name, limit: robot.recording.workflow[0]?.what[0]?.args?.[0]?.limit,