From 5056203023f03a3236b6507af57f43fe8cee1aaa Mon Sep 17 00:00:00 2001 From: Thierry Le Gal Date: Mon, 7 Oct 2019 14:47:20 +0200 Subject: [PATCH] Insert divider in menu by calling RED.menu.addItem('id', null); --- .../@node-red/editor-client/src/js/ui/common/menu.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/node_modules/@node-red/editor-client/src/js/ui/common/menu.js b/packages/node_modules/@node-red/editor-client/src/js/ui/common/menu.js index 131dc1f13..e73c82293 100644 --- a/packages/node_modules/@node-red/editor-client/src/js/ui/common/menu.js +++ b/packages/node_modules/@node-red/editor-client/src/js/ui/common/menu.js @@ -244,7 +244,7 @@ RED.menu = (function() { function addItem(id,opt) { var item = createMenuItem(opt); - if (opt.group) { + if (opt !== null && opt.group) { var groupItems = $("#"+id+"-submenu").children(".red-ui-menu-group-"+opt.group); if (groupItems.length === 0) { item.appendTo("#"+id+"-submenu");