Skip to content

Commit 779eaf0

Browse files
committed
addressed comments
1 parent e4f7821 commit 779eaf0

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

.cursor/rules/global.mdc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ alwaysApply: true
88
You are a professional software engineer. All code must follow best practices: accurate, readable, clean, and efficient.
99

1010
## Logging
11-
Import `createLogger` from `sim/logger`. Use `logger.info`, `logger.warn`, `logger.error` instead of `console.log`.
11+
Import `createLogger` from `@sim/logger`. Use `logger.info`, `logger.warn`, `logger.error` instead of `console.log`.
1212

1313
## Comments
1414
Use TSDoc for documentation. No `====` separators. No non-TSDoc comments.

apps/sim/app/workspace/[workspaceId]/w/[workflowId]/components/panel/components/copilot/components/copilot-message/hooks/use-checkpoint-management.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,6 +187,8 @@ export function useCheckpointManagement(
187187
/** Continues with edit without reverting checkpoint */
188188
const handleContinueWithoutRevert = useCallback(async () => {
189189
setShowCheckpointDiscardModal(false)
190+
onEditModeChange?.(false)
191+
onCancelEdit?.()
190192

191193
if (pendingEditRef.current) {
192194
const { message: msg, fileAttachments, contexts } = pendingEditRef.current
@@ -211,7 +213,7 @@ export function useCheckpointManagement(
211213
}
212214
pendingEditRef.current = null
213215
}
214-
}, [message, messages])
216+
}, [message, messages, onEditModeChange, onCancelEdit])
215217

216218
/** Handles keyboard events for confirmation dialogs */
217219
useEffect(() => {

0 commit comments

Comments
 (0)