Module: HTTMultiParty::ClassMethods
- Defined in:
- lib/httmultiparty.rb
Instance Method Summary collapse
Instance Method Details
#post(path, options = {}) ⇒ Object
76 77 78 79 80 81 82 83 84 |
# File 'lib/httmultiparty.rb', line 76 def post(path, ={}) method = Net::HTTP::Post [:body] ||= .delete(:query) if hash_contains_files?([:body]) method = MultipartPost [:query_string_normalizer] = HTTMultiParty::QUERY_STRING_NORMALIZER end perform_request method, path, end |
#put(path, options = {}) ⇒ Object
86 87 88 89 90 91 92 93 94 |
# File 'lib/httmultiparty.rb', line 86 def put(path, ={}) method = Net::HTTP::Put [:body] ||= .delete(:query) if hash_contains_files?([:body]) method = MultipartPut [:query_string_normalizer] = HTTMultiParty::QUERY_STRING_NORMALIZER end perform_request method, path, end |