Skip to content

Commit 17de21a

Browse files
authored
Merge pull request microsoft#226682 from microsoft/net-bobolink
show useful error message on bad uri
2 parents 13d64e9 + 1184f71 commit 17de21a

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/vs/workbench/services/search/common/textSearchManager.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,9 @@ export class TextSearchManager {
132132
const progress = {
133133
report: (result: TextSearchResultNew) => {
134134

135+
if (result.uri === undefined) {
136+
throw Error('Text search result URI is undefined. Please check provider implementation.');
137+
}
135138
const folderQuery = folderMappings.findSubstr(result.uri)!;
136139
const hasSibling = folderQuery.folder.scheme === Schemas.file ?
137140
hasSiblingPromiseFn(() => {

0 commit comments

Comments
 (0)