Skip to content

Commit

Permalink
fix(#210): Provide a method to return all headers (not only first hea…
Browse files Browse the repository at this point in the history
…der) for a given key in response.go

Signed-off-by: Marcel Oenning <[email protected]>
  • Loading branch information
moenning committed Aug 24, 2021
1 parent 60c8ebd commit fab3b83
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions client/response.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@ func (r response) GetHeader(name string) string {
return r.resp.Header.Get(name)
}

func (r response) GetHeaders(name string) []string {
return r.resp.Header.Values(name)
}

func (r response) Body() io.ReadCloser {
return r.resp.Body
}

0 comments on commit fab3b83

Please sign in to comment.