Specify the CORS headers because it needs that for some reason on some browsers (god I hate CORS)
Signed-off-by: Arzumify <jliwin98@danwin1210.de>
This commit is contained in:
parent
20aa69b26d
commit
7a9af4ae67
|
@ -348,7 +348,7 @@ func Main(information library.ServiceInitializationInformation) *chi.Mux {
|
|||
disableCors := func(next http.Handler) http.Handler {
|
||||
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||
w.Header().Set("Access-Control-Allow-Origin", "*")
|
||||
w.Header().Set("Access-Control-Allow-Headers", "*")
|
||||
w.Header().Set("Access-Control-Allow-Headers", "authorization, content-type")
|
||||
w.Header().Set("Access-Control-Allow-Methods", "*")
|
||||
next.ServeHTTP(w, r)
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue