Browse Source

fix: opening links from popup in Firefox

fixes #1763
tophf 2 years ago
parent
commit
18dcafd8af
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/background/index.js

+ 1 - 1
src/background/index.js

@@ -84,7 +84,7 @@ async function handleCommandMessage({ cmd, data } = {}, src) {
   && (src.origin ? src.origin !== extensionOrigin : !`${src.url}`.startsWith(extensionRoot))) {
     throw new SafeError(`Command is only allowed in extension context: ${cmd}`);
   }
-  if (IS_FIREFOX && !func.isOwn && src && !src.tab) {
+  if (IS_FIREFOX && !func.isOwn && src && !src.tab && !src.url.startsWith(extensionRoot)) {
     if (process.env.DEBUG) console.log('No src.tab, ignoring:', ...arguments);
     return;
   }