about summary refs log tree commit diff stats
path: root/src/assets/javascripts/general.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/assets/javascripts/general.js')
-rw-r--r--src/assets/javascripts/general.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/assets/javascripts/general.js b/src/assets/javascripts/general.js
index 592f604d..7adb0433 100644
--- a/src/assets/javascripts/general.js
+++ b/src/assets/javascripts/general.js
@@ -7,8 +7,10 @@ window.browser = window.browser || window.chrome
 let exceptions
 
 function isException(url) {
-	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 (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
+	}
 	return false
 }