Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Remove check for nil on qs
Fixed by rack/rack-test@4a4b2c1. rack-test was turning the query
string to nil if there was no argument passed in the params. This extra
`nil` check is no longer necessary after the changes made to the
rack-test gem. Fixes issue brought up in #800.
  • Loading branch information
eileencodes committed Mar 1, 2015
1 parent 6f8808d commit 7b45bbd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/rack/utils.rb
Expand Up @@ -109,7 +109,7 @@ def parse_query(qs, d = nil, &unescaper)
# ParameterTypeError is raised. Users are encouraged to return a 400 in this
# case.
def parse_nested_query(qs, d = nil)
return {} if qs.nil? || qs.empty?
return {} if qs.empty?
params = KeySpaceConstrainedParams.new

(qs || '').split(d ? /[#{d}] */n : DEFAULT_SEP).each do |p|
Expand Down

0 comments on commit 7b45bbd

Please sign in to comment.