Merge pull request #988 from dhx/fix/single-character-tld

Allow single character tld (for internal usage)
This commit is contained in:
Daniel Hovie
2022-11-16 09:23:49 +01:00
committed by GitHub

View File

@@ -18,7 +18,7 @@ var (
`\.` + // ending with a dot
`)*` + // end subdomain group, allow any number of subdomains
`(xn--)?` + // TLD idn prefix
`[a-z0-9_-]{2,63}` + // TLD main chunk with at least two characters
`[a-z0-9_-]{1,63}` + // TLD main chunk with at least one character
`\.` + // ending with a dot
`$`, // match end
)