fix(tui): seed moved worktree location (#44143)

Co-authored-by: jlongster <17031+jlongster@users.noreply.github.com>
This commit is contained in:
opencode-agent[bot]
2026-08-22 09:07:27 -04:00
committed by GitHub
Unverified
parent 93e1f383dd
commit 75efc9d833
+4 -2
View File
@@ -34,8 +34,10 @@ export function usePromptMove(input: { projectID: () => string | undefined; sess
const directory = result.directory
if (!directory) throw new Error("No worktree directory returned")
// Call a location-based route to initialize it before moving on.
await client.api.location.get({ location: { directory } })
// Seed the location store before optimistic session creation mounts the
// destination. A raw read initializes the server location but leaves the
// optimistic session without its project until the create request echoes.
await data.location.syncInfo({ directory })
setProgress("Creating session")
return directory