mirror of
https://github.com/halverneus/static-file-server.git
synced 2024-11-13 21:55:31 +00:00
set CORP header (#97)
Co-authored-by: hartenstineh <harry.hartenstine@us.af.mil>
This commit is contained in:
parent
84bb96052a
commit
5d07d4eb3a
@ -168,6 +168,7 @@ func AddCorsWildcardHeaders(serve http.HandlerFunc) http.HandlerFunc {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
w.Header().Set("Access-Control-Allow-Origin", "*")
|
||||
w.Header().Set("Access-Control-Allow-Headers", "*")
|
||||
w.Header().Set("Cross-Origin-Resource-Policy", "cross-origin")
|
||||
serve(w, r)
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user