Skip to content

Commit

Permalink
fix http: superfluous response.WriteHeader call (#2030)
Browse files Browse the repository at this point in the history
  • Loading branch information
wkloucek authored Sep 1, 2021
1 parent eec4c6c commit 784470d
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 5 additions & 0 deletions changelog/unreleased/superfluous-response-write-header.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Bugfix: Fix superfluous WriteHeader on file upload

Removes superfluous Writeheader on file upload and therefore removes the error message "http: superfluous response.WriteHeader call from github.com/cs3org/reva/internal/http/interceptors/log.(*responseLogger).WriteHeader (log.go:154)"

https://github.com/cs3org/reva/pull/2030
1 change: 0 additions & 1 deletion internal/http/services/datagateway/datagateway.go
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,6 @@ func (s *svc) doGet(w http.ResponseWriter, r *http.Request) {
defer httpRes.Body.Close()

copyHeader(w.Header(), httpRes.Header)
w.WriteHeader(httpRes.StatusCode)
switch httpRes.StatusCode {
case http.StatusOK:
case http.StatusPartialContent:
Expand Down

0 comments on commit 784470d

Please sign in to comment.