Skip to content

Commit d7a5212

Browse files
waleedlatif1claude
andcommitted
fix(tables): prevent duplicate undo entry on column drag-drop
Clear dragColumnNameRef immediately in handleColumnDragEnd so the second invocation (from dragend after drop already fired) is a no-op. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent ffe754d commit d7a5212

File tree

1 file changed

+1
-0
lines changed
  • apps/sim/app/workspace/[workspaceId]/tables/[tableId]/components/table

1 file changed

+1
-0
lines changed

apps/sim/app/workspace/[workspaceId]/tables/[tableId]/components/table/table.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -812,6 +812,7 @@ export function Table({
812812
setDropSide('left')
813813
return
814814
}
815+
dragColumnNameRef.current = null
815816
const target = dropTargetColumnNameRef.current
816817
const side = dropSideRef.current
817818
if (target && dragged !== target) {

0 commit comments

Comments
 (0)