File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed
Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -221,5 +221,7 @@ onMounted(refreshCurrentTabUrl);
221221
222222browser .tabs .onUpdated .addListener (refreshCurrentTabUrl);
223223browser .tabs .onActivated .addListener (refreshCurrentTabUrl);
224- browser .windows .onFocusChanged .addListener (refreshCurrentTabUrl);
224+ if (browser .windows ) {
225+ browser .windows .onFocusChanged .addListener (refreshCurrentTabUrl);
226+ }
225227 </script >
Original file line number Diff line number Diff line change @@ -67,7 +67,9 @@ async function openShortcuts() {
6767const shouldShowShortcuts = ref (false );
6868
6969onMounted (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 >
You can’t perform that action at this time.
0 commit comments