The best way to control Claude Code, Codex and more from any computer or phone
fix(web): rewind no longer offers file restore in project-folder threads (#36467)
Julius Marminge committed
Nov 13, 2026 at 17:15 UTC
dea07a1b12d954c2b7f4bfacb47354d9fbb64f5d
2 files changed
+4
apps/web/src/components/ChatView.tsx
+1
@@ -4037,6 +4037,7 @@ export default function ChatView(props: ChatViewProps) {
4037
<RevertConfirmHost
4038
threadKey={routeThreadKey}
4039
checkpoints={serverProjection?.checkpoints}
4040
+ worktreePath={activeThread?.worktreePath ?? null}
4041
onConfirm={onConfirmRevertStable}
4042
/>
4043
{embedded ? null : <LinkPullRequestDialogHost />}
apps/web/src/components/chat/ChatOverlayHosts.tsx
+3
@@ -196,11 +196,14 @@ export function openRevertConfirm(threadKey: string, pending: PendingRevert): vo
196
export function RevertConfirmHost(props: {
197
readonly threadKey: string;
198
readonly checkpoints: OrchestrationV2ThreadProjection["checkpoints"] | undefined;
199
+ readonly worktreePath: string | null;
200
readonly onConfirm: (turnCount: number, messageId: MessageId, restoreFiles: boolean) => void;
201
}) {
202
const pending = useThreadOverlay(revertConfirmAtom, props.threadKey);
203
+ // The server refuses file restore outside an isolated worktree.
204
const canRestoreFiles =
205
pending !== null &&
206
+ props.worktreePath !== null &&
207
findRevertCheckpoint(props.checkpoints ?? [], pending.turnCount)?.status === "ready";
208
const confirm = (restoreFiles: boolean) => {
209
if (pending === null || (restoreFiles && !canRestoreFiles)) return;