instance method
method
Ruby on Rails 8.1.2
Since v3.0.20Signature
method(*args)
Returns the original value of the environment’s REQUEST_METHOD, even if it was overridden by middleware. See #request_method for more information.
For debugging purposes, when called with arguments this method will fall back to Object#method
Parameters
-
argsrest
Source
# File actionpack/lib/action_dispatch/http/request.rb, line 217
def method(*args)
if args.empty?
@method ||= check_method(
get_header("rack.methodoverride.original_method") ||
get_header("REQUEST_METHOD")
)
else
super
end
end
Defined in actionpack/lib/action_dispatch/http/request.rb line 217
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActionDispatch::Request