Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

incorrect TLD #15

Open
tilo opened this issue Jun 10, 2018 · 1 comment
Open

incorrect TLD #15

tilo opened this issue Jun 10, 2018 · 1 comment

Comments

@tilo
Copy link

tilo commented Jun 10, 2018

host = DomainName("example.co.uk-")
host.tld
=> 'uk-'  # not a valid TLD

host = DomainName("example.co.uk ")
host.tld
=> 'uk '  # not a valid TLD (space at the end)

host = DomainName("a.a-a")
host.tld
=> 'a-a '  # not a valid TLD
@sairam
Copy link

sairam commented Jan 19, 2020

@tilo , you can check for host.canonical? or host.canonical_tld?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants