aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2013-01-15 17:26:22 -0800
committerRafael Mendonça França <rafaelmfranca@gmail.com>2013-01-15 17:26:22 -0800
commitcfdd5cbbab68cf34c3fc2248822498191376fe6d (patch)
tree923562fb1525b21383000d7700eced6cd832e0a8 /actionpack/lib
parent8492396e9c1fe21036783d9785ed42c27dee9201 (diff)
parent7925884b5e03127b40f4fd8987b8be115a406c4a (diff)
downloadrails-cfdd5cbbab68cf34c3fc2248822498191376fe6d.tar.gz
rails-cfdd5cbbab68cf34c3fc2248822498191376fe6d.tar.bz2
rails-cfdd5cbbab68cf34c3fc2248822498191376fe6d.zip
Merge pull request #8914 from nilbus/fix-header-bloat
Remove header bloat introduced by BestStandardsSupport middleware
Diffstat (limited to 'actionpack/lib')
-rw-r--r--actionpack/lib/action_dispatch/middleware/best_standards_support.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/actionpack/lib/action_dispatch/middleware/best_standards_support.rb b/actionpack/lib/action_dispatch/middleware/best_standards_support.rb
index d338996240..94efeb79fa 100644
--- a/actionpack/lib/action_dispatch/middleware/best_standards_support.rb
+++ b/actionpack/lib/action_dispatch/middleware/best_standards_support.rb
@@ -17,7 +17,9 @@ module ActionDispatch
status, headers, body = @app.call(env)
if headers["X-UA-Compatible"] && @header
- headers["X-UA-Compatible"] << "," << @header.to_s
+ unless headers["X-UA-Compatible"][@header]
+ headers["X-UA-Compatible"] << "," << @header.to_s
+ end
else
headers["X-UA-Compatible"] = @header
end