From 5829bcae4d4c59a713f96f66864f3e462d472b22 Mon Sep 17 00:00:00 2001 From: BlueRed <146996894+BlueRed-Dev@users.noreply.github.com> Date: Sun, 1 Sep 2024 18:15:53 +0200 Subject: [PATCH] Changed Discord Webhook Regex to allow proxies --- modules/webhook/constants.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/webhook/constants.ts b/modules/webhook/constants.ts index 32afcd44..a384c137 100644 --- a/modules/webhook/constants.ts +++ b/modules/webhook/constants.ts @@ -33,6 +33,6 @@ export const DEFAULT_AVATAR_URL = export const BRANDED_DEFAULT_AVATAR_URL = "/static/discord-avatar.png" export const DEFAULT_DISPLAY_NAME = "Discohook" -export const WEBHOOK_URL_RE = /^https?:\/\/(?:www\.|ptb\.|canary\.)?discord(?:app)?\.com\/api(?:\/v\d+)?\/webhooks\/\d+\/[\w-]+(?:\?thread_id=\d+)?$/ +export const WEBHOOK_URL_RE = /^https?:\/\/(?:[\w-]+\.)?[\w-]+\.[\w-]+\/api(?:\/v\d+)?\/webhooks\/\d+\/[\w-]+(?:\?thread_id=\d+)?$/ export const MESSAGE_REF_RE = /^(?:https:\/\/(?:www\.|ptb\.|canary\.)?discord(?:app)?\.com\/channels\/\d+\/\d+\/)?(\d+)$/