Check for ipcRenderer to prevent unit tests failing
@@ -80,6 +80,7 @@ const plugins = {
}, {})
};
+if (ipcRenderer) {
ipcRenderer.send("set-menu-plugins", plugins.menu);
chokidar
@@ -155,6 +156,7 @@ chokidar
pluginEmitter.emit("remove-menu", { id: pluginId });
ipcRenderer.send("set-menu-plugins", plugins.menu);
});
+}
export default plugins;
export { pluginEmitter };
