diff --git a/golink.go b/golink.go index 83cde7e..560b232 100644 --- a/golink.go +++ b/golink.go @@ -425,8 +425,8 @@ func serveGo(w http.ResponseWriter, r *http.Request) { // http.Redirect always cleans the redirect URL, which we don't always want. // Instead, manually set status and Location header. - w.WriteHeader(http.StatusFound) w.Header().Set("Location", target.String()) + w.WriteHeader(http.StatusFound) } // acceptHTML returns whether the request can accept a text/html response.