tomnomnom / rawhttp

A Go library for making HTTP requests with complete control

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

newResponse reads the body of the response, giving the user no control over how the body is read

tomnomnom opened this issue · comments

The user might not want to read the body at all, so it might be best return an io.ReadCloser the same way net/http does. That io.ReadCloser would be responsible for handling reading content-length, chunked encoding, compression etc.

This would also be more familiar for users of net/http