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

Support RegExp for hasQuery name #274

Closed
mbrodala opened this issue Jan 8, 2016 · 3 comments
Closed

Support RegExp for hasQuery name #274

mbrodala opened this issue Jan 8, 2016 · 3 comments

Comments

@mbrodala
Copy link
Contributor

mbrodala commented Jan 8, 2016

URI.hasQuery does not allow RegExp for parameter names like for values. The following would be a nice complement to the RegExp support in URI.removeQuery:

var uri = URI("http://example.org/?foo[bar]=1&foo[qux]=2");

uri.hasQuery(/^foo/); // true
uri.hasQuery(/^baz/); // false
@rodneyrehm
Copy link
Member

feel free to send a PR for changing URI.hasQuery and its test accordingly

@mbrodala
Copy link
Contributor Author

mbrodala commented Jan 8, 2016

@rodneyrehm Should be straightforward, I'll give it a try.

@rodneyrehm
Copy link
Member

thank you! :)

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

No branches or pull requests

2 participants