add support for flag type params with no value#259
Merged
bradfier merged 1 commit intotomaka:masterfrom Oct 12, 2022
Merged
Conversation
Contributor
Author
|
tests failures appear to be unrelated, looks like the minimum rust version needs to be bumped 1.51 -> 1.56 |
305d1f3 to
b00b2da
Compare
b00b2da to
390048f
Compare
also adding additional test cases to ensure correct behavior.
get_param("reverse") does not return Some("") as expected for query string ?reverse
The expected behavior for URLParams is to treat params with no = in them as if the same as an empty value
localhost:80/api/users?reverse should be equivalent to localhost:80/api/users?reverse=
for reference:
https://developer.mozilla.org/en-US/docs/Web/API/URLSearchParams#empty_value_vs._no_value
390048f to
14e55be
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #258
Adds new testing to cover related edge cases