From a1f1f84aee3bd58378abc251cb5e50cb639bc4ea Mon Sep 17 00:00:00 2001 From: mic Date: Mon, 3 Mar 2025 20:52:58 +0100 Subject: [PATCH] do not get tagslist if permission not given. see #275 --- js/mzta-menus.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/js/mzta-menus.js b/js/mzta-menus.js index e1938693..4c4524da 100644 --- a/js/mzta-menus.js +++ b/js/mzta-menus.js @@ -110,7 +110,12 @@ export class mzta_Menus { let chatgpt_lang = taPromptUtils.getDefaultLang(curr_prompt); let fullPrompt = ''; - let tags_full_list = await getTagsList(); + let tags_full_list = ''; + + // without the tags related permissions, we can't get the tags list + if(await browser.permissions.contains({permissions: ['messagesTagsList']})){ + await getTagsList(); + } let curr_messages = null; switch(tabs[0].type){