Skip to content

Commit

Permalink
return response if client.Do fails
Browse files Browse the repository at this point in the history
  • Loading branch information
marcsauter authored Nov 5, 2018
1 parent c0341ed commit f1022f4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion httpclient.go
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ func (c *Client) Do(ctx context.Context, req *http.Request, v interface{}) (*htt

resp, err := c.client.Do(req.WithContext(ctx))
if err != nil {
return nil, err
return resp, err
}

defer func() {
Expand Down

0 comments on commit f1022f4

Please sign in to comment.