Fix labels for optional auto imports

Fixes #132212
This commit is contained in:
Matt Bierner
2021-09-07 14:54:11 -07:00
parent 183a16d885
commit f1581dcad7

View File

@@ -119,7 +119,11 @@ class MyCompletionItem extends vscode.CompletionItem {
if (!this.filterText) {
this.filterText = this.textLabel;
}
this.label += '?';
if (typeof this.label === 'string') {
this.label += '?';
} else {
this.label.label += '?';
}
}
if (kindModifiers.has(PConst.KindModifiers.deprecated)) {
this.tags = [vscode.CompletionItemTag.Deprecated];