Make http_accept_language work with rails 3.1.0

This commit is contained in:
Tom Hughes 2011-09-24 18:06:23 +01:00
parent 8acdba8bdd
commit 8d520578a1

View file

@ -1,4 +1,6 @@
if defined?(ActionController::Request)
if defined?(ActionDispatch::Request)
ActionDispatch::Request.send :include, HttpAcceptLanguage
elsif defined?(ActionController::Request)
ActionController::Request.send :include, HttpAcceptLanguage
elsif defined?(ActionController::AbstractRequest)
ActionController::AbstractRequest.send :include, HttpAcceptLanguage