Commit 69872685 authored by Jacob Vosmaer's avatar Jacob Vosmaer

Remove unnecessary duplicate variable

parent 7983409a
......@@ -53,13 +53,12 @@ func headerClone(h http.Header) http.Header {
func (u *upstream) proxyRequest(w http.ResponseWriter, r *http.Request) {
// Clone request
req := r
req.Header = headerClone(r.Header)
r.Header = headerClone(r.Header)
// Set Workhorse version
req.Header.Set("Gitlab-Workhorse", Version)
rw := newSendFileResponseWriter(w, req)
r.Header.Set("Gitlab-Workhorse", Version)
rw := newSendFileResponseWriter(w, r)
defer rw.Flush()
u.httpProxy.ServeHTTP(&rw, req)
u.httpProxy.ServeHTTP(&rw, r)
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment