Skip to content

Commit edacb6d

Browse files
fix: Fix issues on Firefox mobile
1 parent 4789aab commit edacb6d

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

src/screens/LinkScreen.vue

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,5 +221,7 @@ onMounted(refreshCurrentTabUrl);
221221
222222
browser.tabs.onUpdated.addListener(refreshCurrentTabUrl);
223223
browser.tabs.onActivated.addListener(refreshCurrentTabUrl);
224-
browser.windows.onFocusChanged.addListener(refreshCurrentTabUrl);
224+
if (browser.windows) {
225+
browser.windows.onFocusChanged.addListener(refreshCurrentTabUrl);
226+
}
225227
</script>

src/screens/MenuScreen.vue

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,9 @@ async function openShortcuts() {
6767
const shouldShowShortcuts = ref(false);
6868
6969
onMounted(async () => {
70-
shouldShowShortcuts.value =
71-
(await browserUtils.isChrome()) || browser.commands.openShortcutSettings != null;
70+
const isChrome = await browserUtils.isChrome();
71+
const hasShortcutCommand = browser.commands && browser.commands.openShortcutSettings != null;
72+
73+
shouldShowShortcuts.value = isChrome || hasShortcutCommand;
7274
});
7375
</script>

0 commit comments

Comments
 (0)