1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

use set_header rather than []=

This allows us to avoid calling `env_name` twice.
This commit is contained in:
Aaron Patterson 2015-08-21 16:43:01 -07:00
parent 1fbf5ad7f7
commit ba2173a10d

View file

@ -82,7 +82,7 @@ module ActionDispatch
# <tt>headers_or_env</tt>.
def merge!(headers_or_env)
headers_or_env.each do |key, value|
self[env_name(key)] = value
@req.set_header env_name(key), value
end
end