Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
Signed-off-by: Patrick Zheng <[email protected]>
  • Loading branch information
Two-Hearts committed Oct 11, 2024
1 parent 6ae5918 commit 6f81322
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/trace/transport.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func (t *Transport) RoundTrip(req *http.Request) (resp *http.Response, err error
var logs strings.Builder
fmt.Fprintf(&logs, "> Request: %q %q\n", req.Method, req.URL)
fmt.Fprintln(&logs, "> Request headers:")
fmt.Fprintln(&logs, logHeader(req.Header))
fmt.Fprint(&logs, logHeader(req.Header))

resp, err = t.RoundTripper.RoundTrip(req)
if err != nil {
Expand All @@ -70,7 +70,7 @@ func (t *Transport) RoundTrip(req *http.Request) (resp *http.Response, err error
} else {
fmt.Fprintf(&logs, "< Response status: %q\n", resp.Status)
fmt.Fprintln(&logs, "< Response headers:")
fmt.Fprintln(&logs, logHeader(resp.Header))
fmt.Fprint(&logs, logHeader(resp.Header))
e.Debug(logs.String())
}
return resp, err
Expand Down

0 comments on commit 6f81322

Please sign in to comment.