-
Notifications
You must be signed in to change notification settings - Fork 84
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
Make .forHostname() hostname parameter a RegExp #82
Comments
👍 Sounds good to me, PRs welcome. The one tricky bit is serialization for remote clients, since JSON can't represent regexes natively. You can see how RegexPathMatcher handles it here - it stores the regex as a string, which only gets converted into a regex inside I think I'd suggest creating this as a new matcher like |
Got you! |
I'd propose to make hostname a RegExp.
First, to match things like:
.forHostname(/^.+?\.domain.com/)
Second, to keep up with the URL matchers (
.forGet()
,.forPost()
etc) which can takeRegExp
.I.e.
gets:
The text was updated successfully, but these errors were encountered: