Don't add CORS headers for Webfinger in production
Some checks failed
continuous-integration/drone/push Build is failing

The reverse proxy should handle it.
This commit is contained in:
Râu Cao 2024-01-26 11:01:45 +03:00
parent c32fc51aab
commit 243cf9c08d
Signed by: raucao
GPG Key ID: 37036C356E56CC51

View File

@ -54,7 +54,8 @@ class WebfingerController < ApplicationController
end
def allow_cross_origin_requests
headers['Access-Control-Allow-Origin'] = '*'
headers['Access-Control-Allow-Methods'] = 'GET, POST, PUT, OPTIONS'
return unless Rails.env.development?
headers['Access-Control-Allow-Origin'] = "*"
headers['Access-Control-Allow-Methods'] = "GET"
end
end