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

Email as username breaks all methods to get parts of authority: host(), port(), username(), etc. #108

Closed
caseydawsonjordan opened this issue Aug 13, 2013 · 2 comments
Labels

Comments

@caseydawsonjordan
Copy link

var uri = URI("http://john@doe.com:pass@example.org:8080/some/path/foo.html?hello=world#target/here")

uri.host() => "doe.com:pass@example.org:8080" should be "example.org"

See: http://jsfiddle.net/3SvmV/1/

@rodneyrehm
Copy link
Member

nice catch!

@rodneyrehm
Copy link
Member

I've modified the parser to accept your input. you should be aware of the fact that the URI you provided is malformed - i.e. the @ needs to be percent-encoded. This is fixed in master and will be included in the next release.

Thank you!

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

No branches or pull requests

2 participants