Stop wrapping function for no reason.

This commit is contained in:
picklesrus 2018-03-02 10:58:43 -08:00
parent 1910968b13
commit 026b9dc282

View file

@ -553,9 +553,7 @@ class Runtime extends EventEmitter {
const menuId = this._makeExtensionMenuId(menuName, categoryInfo.id);
let options = null;
if (typeof menuItems === 'function') {
options = function () {
return menuItems();
};
options = menuItems;
} else {
options = menuItems.map(item => {
switch (typeof item) {