diff options
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/CHANGELOG | 2 | ||||
-rw-r--r-- | actionpack/lib/action_controller/cgi_process.rb | 13 |
2 files changed, 9 insertions, 6 deletions
diff --git a/actionpack/CHANGELOG b/actionpack/CHANGELOG index 0ae11330e0..b6c03940c3 100644 --- a/actionpack/CHANGELOG +++ b/actionpack/CHANGELOG @@ -1,6 +1,6 @@ *SVN* -* Performance tweaks: use Set instead of Array to speed up prototype helper include? calls. Avoid logging code if logger is nil. Inline commonly-called template presence checks. #2880, #2881, #2882 [Stefan Kaes] +* Performance tweaks: use Set instead of Array to speed up prototype helper include? calls. Avoid logging code if logger is nil. Inline commonly-called template presence checks. #2880, #2881, #2882, #2883 [Stefan Kaes] * MemCache store may be given multiple addresses. #2869 [Ryan Carver <ryan@fivesevensix.com>] diff --git a/actionpack/lib/action_controller/cgi_process.rb b/actionpack/lib/action_controller/cgi_process.rb index 51a0433a89..812899b327 100644 --- a/actionpack/lib/action_controller/cgi_process.rb +++ b/actionpack/lib/action_controller/cgi_process.rb @@ -183,11 +183,14 @@ end_msg private def convert_content_type!(headers) - %w( Content-Type Content-type content-type ).each do |ct| - if headers[ct] - headers["type"] = headers[ct] - headers.delete(ct) - end + if header = headers.delete("Content-Type") + headers["type"] = header + end + if header = headers.delete("Content-type") + headers["type"] = header + end + if header = headers.delete("content-type") + headers["type"] = header end end end |