MCPcopy Index your code
hub / github.com/continuedev/continue / deleteChain

Method deleteChain

core/nextEdit/NextEditProvider.ts:222–243  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

220 }
221
222 public async deleteChain(): Promise<void> {
223 PrefetchQueue.getInstance().abort();
224
225 this.currentEditChainId = null;
226 this.previousCompletions = [];
227
228 if (this.previousRequest) {
229 const fileContent = (
230 await this.ide.readFile(this.previousRequest.filepath)
231 ).toString();
232
233 const ast = await getAst(this.previousRequest.filepath, fileContent);
234
235 if (ast) {
236 DocumentHistoryTracker.getInstance().push(
237 localPathOrUriToPath(this.previousRequest.filepath),
238 fileContent,
239 ast,
240 );
241 }
242 }
243 }
244
245 public startChain(id?: string) {
246 this.currentEditChainId = id ?? uuidv4();

Callers 6

registerKeyListenersMethod · 0.80
constructorMethod · 0.80

Calls 6

getAstFunction · 0.85
localPathOrUriToPathFunction · 0.85
readFileMethod · 0.65
pushMethod · 0.65
abortMethod · 0.45
getInstanceMethod · 0.45

Tested by

no test coverage detected