about summary refs log tree commit diff stats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/assets/javascripts/services.js2
-rw-r--r--src/config.json19
2 files changed, 20 insertions, 1 deletions
diff --git a/src/assets/javascripts/services.js b/src/assets/javascripts/services.js
index fc610afb..971fb615 100644
--- a/src/assets/javascripts/services.js
+++ b/src/assets/javascripts/services.js
@@ -63,13 +63,13 @@ function redirect(url, type, initiator, forceRedirection) {
 		) return "BYPASSTAB"
 
 		let instanceList = options[frontend]
+		if (instanceList === undefined) break
 		if (instanceList.length === 0) return
 
 		randomInstance = utils.getRandomInstance(instanceList)
 
 		break
 	}
-	if (!randomInstance) return
 
 	// Here is a (temperory) space for defining constants required in 2 or more switch cases.
 	const mapCentreRegex = /@(-?\d[0-9.]*),(-?\d[0-9.]*),(\d{1,2})[.z]/
diff --git a/src/config.json b/src/config.json
index 07d10f4b..8e3d2711 100644
--- a/src/config.json
+++ b/src/config.json
@@ -497,6 +497,25 @@
 			"imageType": "svg",
 			"embeddable": false,
 			"url": "https://genius.com"
+		},
+		"urbanDictionary": {
+			"frontends": {
+				"ruralDictionary": {
+					"name": "Rural Dictionary",
+					"instanceList": true,
+					"url": "https://codeberg.org/zortazert/rural-dictionary"
+				}
+			},
+			"targets": [
+				"^https?:\\/{2}(www\\.)?urbandictionary.com\\/"
+			],
+			"name": "Urban Dictionary",
+			"options": {
+				"enabled": false
+			},
+			"imageType": "svg",
+			"embeddable": false,
+			"url": "https://genius.com"
 		}
 	}
 }
\ No newline at end of file