Skip to content

Commit 7394fa1

Browse files
committed
Fixes a few more cases of microsoft#211878
1 parent d1b5d42 commit 7394fa1

File tree

4 files changed

+11
-10
lines changed

4 files changed

+11
-10
lines changed

src/vs/workbench/contrib/extensions/browser/languageRecommendations.ts

+1-3
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ export class LanguageRecommendations extends ExtensionRecommendations {
2020

2121
protected async doActivate(): Promise<void> {
2222
if (this.productService.languageExtensionTips) {
23-
this._recommendations = this.productService.languageExtensionTips.map(extensionId => (<ExtensionRecommendation>{
23+
this._recommendations = this.productService.languageExtensionTips.map((extensionId): ExtensionRecommendation => ({
2424
extension: extensionId.toLowerCase(),
2525
reason: {
2626
reasonId: ExtensionRecommendationReason.Application,
@@ -29,6 +29,4 @@ export class LanguageRecommendations extends ExtensionRecommendations {
2929
}));
3030
}
3131
}
32-
3332
}
34-

src/vs/workbench/contrib/logs/common/logsActions.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ export class OpenWindowSessionLogFileAction extends Action {
171171

172172
override async run(): Promise<void> {
173173
const sessionResult = await this.quickInputService.pick(
174-
this.getSessions().then(sessions => sessions.map((s, index) => (<IQuickPickItem>{
174+
this.getSessions().then(sessions => sessions.map((s, index): IQuickPickItem => ({
175175
id: s.toString(),
176176
label: basename(s),
177177
description: index === 0 ? nls.localize('current', "Current") : undefined
@@ -182,7 +182,7 @@ export class OpenWindowSessionLogFileAction extends Action {
182182
});
183183
if (sessionResult) {
184184
const logFileResult = await this.quickInputService.pick(
185-
this.getLogFiles(URI.parse(sessionResult.id!)).then(logFiles => logFiles.map(s => (<IQuickPickItem>{
185+
this.getLogFiles(URI.parse(sessionResult.id!)).then(logFiles => logFiles.map((s): IQuickPickItem => ({
186186
id: s.toString(),
187187
label: basename(s)
188188
}))),

src/vs/workbench/contrib/markers/browser/markersViewActions.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ export class MarkersFilters extends Disposable {
9292
set showErrors(showErrors: boolean) {
9393
if (this._showErrors.get() !== showErrors) {
9494
this._showErrors.set(showErrors);
95-
this._onDidChange.fire(<IMarkersFiltersChangeEvent>{ showErrors: true });
95+
this._onDidChange.fire({ showErrors: true });
9696
}
9797
}
9898

@@ -103,7 +103,7 @@ export class MarkersFilters extends Disposable {
103103
set showInfos(showInfos: boolean) {
104104
if (this._showInfos.get() !== showInfos) {
105105
this._showInfos.set(showInfos);
106-
this._onDidChange.fire(<IMarkersFiltersChangeEvent>{ showInfos: true });
106+
this._onDidChange.fire({ showInfos: true });
107107
}
108108
}
109109

src/vs/workbench/contrib/workspace/browser/workspaceTrustEditor.ts

+6-3
Original file line numberDiff line numberDiff line change
@@ -431,7 +431,8 @@ class TrustedUriActionsColumnRenderer implements ITableRenderer<ITrustedUriItem,
431431
}
432432

433433
private createEditAction(item: ITrustedUriItem): IAction {
434-
return <IAction>{
434+
return {
435+
label: '',
435436
class: ThemeIcon.asClassName(editIcon),
436437
enabled: true,
437438
id: 'editTrustedUri',
@@ -443,7 +444,8 @@ class TrustedUriActionsColumnRenderer implements ITableRenderer<ITrustedUriItem,
443444
}
444445

445446
private createPickerAction(item: ITrustedUriItem): IAction {
446-
return <IAction>{
447+
return {
448+
label: '',
447449
class: ThemeIcon.asClassName(folderPickerIcon),
448450
enabled: true,
449451
id: 'pickerTrustedUri',
@@ -455,7 +457,8 @@ class TrustedUriActionsColumnRenderer implements ITableRenderer<ITrustedUriItem,
455457
}
456458

457459
private createDeleteAction(item: ITrustedUriItem): IAction {
458-
return <IAction>{
460+
return {
461+
label: '',
459462
class: ThemeIcon.asClassName(removeIcon),
460463
enabled: true,
461464
id: 'deleteTrustedUri',

0 commit comments

Comments
 (0)