diff --git a/client/modules/user-menu/index.js b/client/modules/user-menu/index.js index d76733b5..0494b42b 100644 --- a/client/modules/user-menu/index.js +++ b/client/modules/user-menu/index.js @@ -75,9 +75,8 @@ async function show() { function fillTemplate(options) { const result = []; - for (const option of options) { + for (const option of options) result.push(``); - } return result.join(''); } @@ -125,7 +124,12 @@ const runUserMenu = async (value, options, userMenu) => { tryToCatch, }); - if (e) - Dialog.alert(e.stack); + if (!e) + return; + + if (e.name === 'Error') + return Dialog.alert(e.message); + + return Dialog.alert(e.stack); };