diff --git a/cmd/changelog-remote/main.go b/cmd/changelog-remote/main.go index 5df9f0df..b63ea946 100644 --- a/cmd/changelog-remote/main.go +++ b/cmd/changelog-remote/main.go @@ -66,6 +66,10 @@ func generate(remote string, version string) ([]byte, error) { } func handler(w http.ResponseWriter, r *http.Request) { + // cors + w.Header().Set("Access-Control-Allow-Origin", r.Header.Get("Origin")) + w.Header().Set("Access-Control-Allow-Methods", "GET") + query := r.URL.Query() username := query.Get("username")