Class: OAuth::RequestProxy::Net::HTTP::HTTPRequest

Inherits:
Base
  • Object
show all
Defined in:
lib/patches.rb

Instance Method Summary collapse

Instance Method Details

#query_stringObject



34
35
36
37
38
39
# File 'lib/patches.rb', line 34

def query_string
  params = [ query_params, auth_header_params ]
  is_form_urlencoded = request['Content-Type'] != nil && request['Content-Type'].downcase == 'application/x-www-form-urlencoded'
  params << post_params if ['POST', 'PUT'].include?(method.to_s.upcase) && is_form_urlencoded
  params.compact.join('&')
end