copy resp.Body to *bytes.Buffer

1,045 views
Skip to first unread message

RS

unread,
Oct 7, 2021, 8:13:17 AM10/7/21
to golang-nuts
How can I copy resp.Body  to a *bytes.Buffer?

I am new to go. 
resp.Body is the response which I get from client.Do, and is of type *http.Response

Ross Light

unread,
Oct 7, 2021, 3:55:45 PM10/7/21
to golang-nuts
Reply all
Reply to author
Forward
0 new messages