aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/Menu.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/Menu.js')
-rw-r--r--src/lib/Menu.js24
1 files changed, 11 insertions, 13 deletions
diff --git a/src/lib/Menu.js b/src/lib/Menu.js
index c60536f0c..756b256fb 100644
--- a/src/lib/Menu.js
+++ b/src/lib/Menu.js
@@ -831,8 +831,8 @@ export default class FranzMenu {
831 // need to clone object so we don't modify computed (cached) object 831 // need to clone object so we don't modify computed (cached) object
832 const serviceTpl = Object.assign([], this.serviceTpl()); 832 const serviceTpl = Object.assign([], this.serviceTpl());
833 833
834 // Don't initialize when window.franz is undefined or when we are on a payment window route 834 // Don't initialize when window.ferdi is undefined
835 if (window.ferdi === undefined || this.stores.router.location.pathname.startsWith('/payment/')) { 835 if (window.ferdi === undefined) {
836 console.log('skipping menu init'); 836 console.log('skipping menu init');
837 return; 837 return;
838 } 838 }
@@ -1219,17 +1219,15 @@ export default class FranzMenu {
1219 }); 1219 });
1220 1220
1221 // Workspace items 1221 // Workspace items
1222 if (this.stores.user.isPremium) { 1222 workspaces.forEach((workspace, i) => menu.push({
1223 workspaces.forEach((workspace, i) => menu.push({ 1223 label: workspace.name,
1224 label: workspace.name, 1224 accelerator: i < 9 ? `${cmdKey}+Alt+${i + 1}` : null,
1225 accelerator: i < 9 ? `${cmdKey}+Alt+${i + 1}` : null, 1225 type: 'radio',
1226 type: 'radio', 1226 checked: activeWorkspace ? workspace.id === activeWorkspace.id : false,
1227 checked: activeWorkspace ? workspace.id === activeWorkspace.id : false, 1227 click: () => {
1228 click: () => { 1228 workspaceActions.activate({ workspace });
1229 workspaceActions.activate({ workspace }); 1229 },
1230 }, 1230 }));
1231 }));
1232 }
1233 1231
1234 return menu; 1232 return menu;
1235 } 1233 }