chore: remove unused code

This commit is contained in:
amhsirak
2024-11-18 06:12:17 +05:30
parent 874ee8d9e7
commit 1af3e68ffd

View File

@@ -59,17 +59,8 @@ interface RobotSettingsProps {
export const RobotEditModal = ({ isOpen, handleStart, handleClose, initialSettings }: RobotSettingsProps) => {
const [robot, setRobot] = useState<RobotSettings | null>(null);
// const [settings, setSettings] = useState<RobotEditOptions>({
// name: '',
// });
// const [userEmail, setUserEmail] = useState<string | null>(null);
const { recordingId, notify } = useGlobalInfoStore();
// const handleChange = (field: keyof RobotEditOptions, value: string | number | boolean) => {
// setSettings(prev => ({ ...prev, [field]: value }));
// };
useEffect(() => {
if (isOpen) {
getRobot();
@@ -137,23 +128,6 @@ export const RobotEditModal = ({ isOpen, handleStart, handleClose, initialSettin
}
};
// const lastPair = robot?.recording.workflow[robot?.recording.workflow.length - 1];
// Find the `goto` action in `what` and retrieve its arguments
// const targetUrl = lastPair?.what.find(action => action.action === "goto")?.args?.[0];
// useEffect(() => {
// const fetchUserEmail = async () => {
// if (robot && robot.userId) {
// const userData = await getUserById(robot.userId.toString());
// if (userData && userData.user) {
// setUserEmail(userData.user.email);
// }
// }
// };
// fetchUserEmail();
// }, [robot?.userId]);
return (
<GenericModal
isOpen={isOpen}