MCPcopy
hub / github.com/davecheney/httpstat / isRedirect

Function isRedirect

main.go:391–393  ·  view source on GitHub ↗
(resp *http.Response)

Source from the content-addressed store, hash-verified

389}
390
391func isRedirect(resp *http.Response) bool {
392 return resp.StatusCode > 299 && resp.StatusCode < 400
393}
394
395func newRequest(method string, url *url.URL, body string) *http.Request {
396 req, err := http.NewRequest(method, url.String(), createBody(body))

Callers 2

visitFunction · 0.85
readResponseBodyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected