authorgravatar for julius0216@outlook.comJulius Marminge <julius0216@outlook.com> 2026-02-26 18:43:57-08:00
committergravatar for jmarminge@gmail.comJulius Marminge <jmarminge@gmail.com> 2026-02-26 20:51:29-08:00
logf6e7166e7955af6c06881cfecf6d869854cf191e
treeafb87b333f93ca3ef8f242fc8f84bf9072757aa9
parent2da82900409fe231fb913df2c61b580f1a453924

Capture threadId before async send flow

- Store `activeThread.id` once at send start and reuse it - Prevents updates/errors from targeting the wrong thread during async worktree/send steps

1 files changed, 1 insertions(+), 1 deletions(-)

apps/web/src/components/ChatView.tsx+1-1
......@@ -1466,7 +1466,7 @@ export default function ChatView({ threadId }: ChatViewProps) {
14661466 // with the worktree cwd/env instead of briefly using the project root.
14671467 dispatch({
14681468 type: "SET_THREAD_BRANCH",
1469 threadId: activeThread.id,
1469 threadId: threadIdForSend,
14701470 branch: result.worktree.branch,
14711471 worktreePath: result.worktree.path,
14721472 });