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

Make query parameters without = have empty string values #2098

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

jeremyevans
Copy link
Contributor

This was reverted in 77cf057 so that Rails could have historical Rack behavior without the complexity of splitting form/query parsing.

Now that splitting form/query parsing has been added back in 3855d1d, this changes the behavior to what originally shipped in Rack 3.

This matches URL spec section 5.1.3.3. Frameworks that want Rack's historical behavior of using nil values instead of empty string values can reparse QUERY_STRING and use rack.request.form_pairs to get the behavior they want.

This was reverted in 77cf057
so that Rails could have historical Rack behavior without the
complexity of splitting form/query parsing.

Now that splitting form/query parsing has been added back in
3855d1d, this changes the
behavior to what originally shipped in Rack 3.

This matches URL spec section 5.1.3.3.  Frameworks that want
Rack's historical behavior of using nil values instead of
empty string values can reparse QUERY_STRING and use
rack.request.form_pairs to get the behavior they want.
@dentarg
Copy link
Contributor

dentarg commented Jul 19, 2023

Is this going to ship with Rack 3.1?

@dentarg dentarg mentioned this pull request Jul 19, 2023
7 tasks
@ioquatix
Copy link
Member

ioquatix commented Jul 19, 2023

I suggest we consider this for Rack 3.2+ or 4.0. Maybe we can introduce missing_value and keep the default the same in 3.x and change it for 4.x?

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

Successfully merging this pull request may close these issues.

None yet

3 participants