diff --git a/discord/webhook/async_.py b/discord/webhook/async_.py index 8e002abe9..7e4286e89 100644 --- a/discord/webhook/async_.py +++ b/discord/webhook/async_.py @@ -1227,7 +1227,7 @@ class Webhook(BaseWebhook): A partial :class:`Webhook`. A partial webhook is just a webhook object with an ID and a token. """ - m = re.search(r'discord(?:app)?.com/api/webhooks/(?P[0-9]{17,20})/(?P[A-Za-z0-9\.\-\_]{60,68})', url) + m = re.search(r'discord(?:app)?\.com/api/webhooks/(?P[0-9]{17,20})/(?P[A-Za-z0-9\.\-\_]{60,68})', url) if m is None: raise ValueError('Invalid webhook URL given.') diff --git a/discord/webhook/sync.py b/discord/webhook/sync.py index 1eed37ee2..8cb5eb20e 100644 --- a/discord/webhook/sync.py +++ b/discord/webhook/sync.py @@ -683,7 +683,7 @@ class SyncWebhook(BaseWebhook): A partial :class:`Webhook`. A partial webhook is just a webhook object with an ID and a token. """ - m = re.search(r'discord(?:app)?.com/api/webhooks/(?P[0-9]{17,20})/(?P[A-Za-z0-9\.\-\_]{60,68})', url) + m = re.search(r'discord(?:app)?\.com/api/webhooks/(?P[0-9]{17,20})/(?P[A-Za-z0-9\.\-\_]{60,68})', url) if m is None: raise ValueError('Invalid webhook URL given.')