Make it possible to add multiple CORS origins in discourse.conf and docker yml files
This commit is contained in:
parent
4a2d6bd5da
commit
10f0ddbbdd
|
@ -3,7 +3,7 @@ if GlobalSetting.enable_cors
|
|||
|
||||
Rails.configuration.middleware.use Rack::Cors do
|
||||
allow do
|
||||
origins GlobalSetting.cors_origin
|
||||
origins GlobalSetting.cors_origin.split(',').map(&:strip)
|
||||
resource '*', headers: :any, methods: [:get, :post, :options]
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue