Merge branch 'corss-fix' into 'dev'

Adjusted access-control-allow-headers

See merge request sa4-2020/the-sanmarinoes/backend!20
This commit is contained in:
Claudio Maggioni 2020-03-03 12:15:59 +01:00
commit 5a5cc2e013

View file

@ -20,7 +20,9 @@ public class CORSFilter implements Filter {
response.setHeader("Access-Control-Allow-Origin", "*");
response.setHeader("Access-Control-Allow-Methods", "HEAD, PUT, POST, GET, OPTIONS, DELETE");
response.setHeader("Access-Control-Max-Age", "3600");
response.setHeader("Access-Control-Allow-Headers", "x-requested-with");
response.setHeader(
"Access-Control-Allow-Headers",
"Access-Control-Allow-Headers, Origin,Accept, X-Requested-With, Content-Type, Access-Control-Request-Method, Access-Control-Request-Headers");
chain.doFilter(req, res);
}