make sure to cancel current request on restore checkpoints (#306901)

This commit is contained in:
Justin Chen
2026-03-31 11:41:40 -07:00
committed by GitHub
parent 1c1dc9f684
commit 213b27d7c3

View File

@@ -495,6 +495,8 @@ async function restoreSnapshotWithConfirmationByRequestId(accessor: ServicesAcce
await configurationService.updateValue('chat.editing.confirmEditRequestRemoval', false);
}
await chatService.cancelCurrentRequestForSession(sessionResource, 'restoreCheckpoint');
// Restore the snapshot to what it was before the request(s) that we deleted
const snapshotRequestId = chatRequests[itemIndex].id;
await session.restoreSnapshot(snapshotRequestId, undefined);