instance method
to_a
Ruby on Rails 4.2.9
Since v3.0.20Signature
to_a()
Turns the Response into a Rack-compatible array of the status, headers, and body. Allows explict splatting:
status, headers, body = *response
Source
# File actionpack/lib/action_dispatch/http/response.rb, line 283
def to_a
rack_response @status, @header.to_hash
end
Defined in actionpack/lib/action_dispatch/http/response.rb line 283
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActionDispatch::Response