We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bafaf69 commit 7dfdd3fCopy full SHA for 7dfdd3f
pydis_core/utils/regex.py
@@ -5,13 +5,8 @@
5
DISCORD_INVITE = re.compile(
6
r"(https?://)?(www\.)?" # Optional http(s) and www.
7
r"(discord(app)?)?" # Optional discord(app)
8
- r"("
9
- r"([.,]|dot)gg|" # Could be .gg
10
- r"([.,]|dot)com|" # or .com
11
- r"([.,]|dot)me|" # or .me
12
- r"([.,]|dot)li|" # or .li
13
- r"([.,]|dot)io" # or .io
14
- r")"
+ r"([.,]|dot)" # Various characters to cover dots
+ r"(gg|com|me|li|io)" # A few TLDs that embed within discord
15
r"((/|slash|\\)(invite))?" # / or \ or 'slash' invite
16
r"(/|slash|\\)" # / or \ or 'slash'
17
r"(?P<invite>\S+)", # the invite code itself
0 commit comments