instance method
merge
Ruby on Rails 4.2.9
Since v4.0.13Signature
merge(headers_or_env)
Returns a new Http::Headers instance containing the contents of headers_or_env and the original instance.
Parameters
-
headers_or_envreq
Source
# File actionpack/lib/action_dispatch/http/headers.rb, line 71
def merge(headers_or_env)
headers = Http::Headers.new(env.dup)
headers.merge!(headers_or_env)
headers
end
Defined in actionpack/lib/action_dispatch/http/headers.rb line 71
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActionDispatch::Http::Headers