Only allow open CORS on the api

This commit is contained in:
Brenda Wallace
2020-05-31 12:58:26 +12:00
committed by Brenda Wallace
parent 32972a90fd
commit 5600670fef

View File

@@ -108,7 +108,7 @@ module Growstuff
config.middleware.insert_before 0, Rack::Cors do
allow do
origins '*'
resource '*', headers: :any, methods: [:get, :post, :options]
resource '/api/v1/*', headers: :any, methods: [:get, :post, :options]
end
end
end