Skip to content

Commit

Permalink
But we also don't want separators at the end
Browse files Browse the repository at this point in the history
  • Loading branch information
Colin Grant committed Jul 11, 2022
1 parent 227e46f commit 198a462
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/core/src/browser/menu/browser-menu-plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ export class DynamicMenuWidget extends MenuWidget {

protected updateSubMenus(parent: MenuWidget, menu: CompositeMenuNode, commands: MenuCommandRegistry): void {
const items = this.buildSubMenus([], menu, commands);
if (items[items.length - 1]?.type === 'separator') {
while (items[items.length - 1]?.type === 'separator') {
items.pop();
}
for (const item of items) {
Expand Down

0 comments on commit 198a462

Please sign in to comment.