Skip to content

Commit

Permalink
💄 better strict property init
Browse files Browse the repository at this point in the history
  • Loading branch information
jrieken committed Nov 21, 2019
1 parent 760e07d commit 8da81e5
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/vs/platform/actions/common/menuService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ class Menu implements IMenu {
private readonly _onDidChange = new Emitter<IMenu | undefined>();
private readonly _dispoables = new DisposableStore();

private _menuGroups!: MenuItemGroup[];
private _contextKeys!: Set<string>;
private _menuGroups: MenuItemGroup[] = [];
private _contextKeys: Set<string> = new Set();

constructor(
private readonly _id: MenuId,
Expand Down Expand Up @@ -67,8 +67,8 @@ class Menu implements IMenu {
private _build(): void {

// reset
this._menuGroups = [];
this._contextKeys = new Set();
this._menuGroups.length = 0;
this._contextKeys.clear();

const menuItems = MenuRegistry.getMenuItems(this._id);

Expand Down

0 comments on commit 8da81e5

Please sign in to comment.