mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-23 10:08:49 +01:00
Fix #57951 - remove $cancelSearch
This commit is contained in:
@@ -93,7 +93,7 @@ export class ExtHostSearch implements ExtHostSearchShape {
|
||||
});
|
||||
} else {
|
||||
const indexProvider = this._fileIndexProvider.get(handle);
|
||||
return this._fileIndexSearchManager.fileSearch(query, indexProvider, batch => {
|
||||
const searchP = this._fileIndexSearchManager.fileSearch(query, indexProvider, batch => {
|
||||
this._proxy.$handleFileMatch(handle, session, batch.map(p => p.resource));
|
||||
}).then(null, err => {
|
||||
if (!isPromiseCanceledError(err)) {
|
||||
@@ -102,6 +102,10 @@ export class ExtHostSearch implements ExtHostSearchShape {
|
||||
|
||||
return null;
|
||||
});
|
||||
|
||||
token.onCancellationRequested(() => searchP.cancel());
|
||||
|
||||
return searchP;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user