do not overwrite hostname in development (#6623)
This commit is contained in:
parent
1b4f2029d7
commit
e25b3965a7
|
@ -198,8 +198,10 @@ module Discourse
|
|||
# supports etags (post 1.7)
|
||||
config.middleware.delete Rack::ETag
|
||||
|
||||
require 'middleware/enforce_hostname'
|
||||
config.middleware.insert_after Rack::MethodOverride, Middleware::EnforceHostname
|
||||
unless Rails.env.development?
|
||||
require 'middleware/enforce_hostname'
|
||||
config.middleware.insert_after Rack::MethodOverride, Middleware::EnforceHostname
|
||||
end
|
||||
|
||||
require 'content_security_policy'
|
||||
config.middleware.swap ActionDispatch::ContentSecurityPolicy::Middleware, ContentSecurityPolicy::Middleware
|
||||
|
|
Loading…
Reference in New Issue