mirror of
https://github.com/lostisland/faraday.git
synced 2025-10-03 00:02:48 -04:00
Alias Faraday::Request #method
to #http_method
.
This change is to make Faraday 0.x forward-compatible with 1.x and 2.x change of the parameter name.
This commit is contained in:
parent
2f3a7da89e
commit
b80302d602
@ -12,6 +12,8 @@ module Faraday
|
||||
class Request < Struct.new(:method, :path, :params, :headers, :body, :options)
|
||||
extend MiddlewareRegistry
|
||||
|
||||
alias_method :http_method, :method
|
||||
|
||||
register_middleware File.expand_path('../request', __FILE__),
|
||||
:url_encoded => [:UrlEncoded, 'url_encoded'],
|
||||
:multipart => [:Multipart, 'multipart'],
|
||||
|
Loading…
x
Reference in New Issue
Block a user