diff options
author | ManeraKai <manerakai@protonmail.com> | 2023-03-05 20:07:11 +0300 |
---|---|---|
committer | ManeraKai <manerakai@protonmail.com> | 2023-03-05 20:07:11 +0300 |
commit | 10b4fd960162f6636ef6bd6969b73885ee93b20c (patch) | |
tree | ac372da0902430cf0dcc17e826ea618176f827cb /src/assets/javascripts | |
parent | Fixed bugs in the context menus (diff) | |
download | libredirect-10b4fd960162f6636ef6bd6969b73885ee93b20c.zip |
Fixed reverse tab for context menu for chromium
Diffstat (limited to 'src/assets/javascripts')
-rw-r--r-- | src/assets/javascripts/general.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/assets/javascripts/general.js b/src/assets/javascripts/general.js index 7adb0433..588c67d1 100644 --- a/src/assets/javascripts/general.js +++ b/src/assets/javascripts/general.js @@ -7,9 +7,9 @@ window.browser = window.browser || window.chrome let exceptions function isException(url) { - if (url !== undefined) { - for (const item of exceptions.url) if (item == url.href) return true - for (const item of exceptions.regex) if (new RegExp(item).test(url.href)) return true + if (exceptions && url) { + if (exceptions.url) for (const item of exceptions.url) if (item == url.href) return true + if (exceptions.regex) for (const item of exceptions.regex) if (new RegExp(item).test(url.href)) return true } return false } |