mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-19 16:18:58 +01:00
Some chat service cleanup (#280105)
* Clean up unused cancel token * Simplify shouldBeInHistory * Use real DisposableResourceMap
This commit is contained in:
@@ -1662,7 +1662,7 @@ export async function reviewEdits(accessor: ServicesAccessor, editor: ICodeEdito
|
||||
|
||||
const chatService = accessor.get(IChatService);
|
||||
const uri = editor.getModel().uri;
|
||||
const chatModelRef = chatService.startSession(ChatAgentLocation.EditorInline, token);
|
||||
const chatModelRef = chatService.startSession(ChatAgentLocation.EditorInline);
|
||||
const chatModel = chatModelRef.object as ChatModel;
|
||||
|
||||
chatModel.startEditingSession(true);
|
||||
@@ -1714,7 +1714,7 @@ export async function reviewNotebookEdits(accessor: ServicesAccessor, uri: URI,
|
||||
const chatService = accessor.get(IChatService);
|
||||
const notebookService = accessor.get(INotebookService);
|
||||
const isNotebook = notebookService.hasSupportedNotebooks(uri);
|
||||
const chatModelRef = chatService.startSession(ChatAgentLocation.EditorInline, token);
|
||||
const chatModelRef = chatService.startSession(ChatAgentLocation.EditorInline);
|
||||
const chatModel = chatModelRef.object as ChatModel;
|
||||
|
||||
chatModel.startEditingSession(true);
|
||||
|
||||
Reference in New Issue
Block a user