mirror of
https://github.com/golang/go
synced 2024-11-20 08:04:42 -07:00
http: cleaned up HEAD request method.
Removed a redefinition of the request URL which is never used and redundant checking of the return value from send(). R=golang-dev, adg CC=golang-dev https://golang.org/cl/4184061
This commit is contained in:
parent
c010b0e846
commit
1f39ed8a2d
@ -321,11 +321,7 @@ func Head(url string) (r *Response, err os.Error) {
|
||||
if req.URL, err = ParseURL(url); err != nil {
|
||||
return
|
||||
}
|
||||
url = req.URL.String()
|
||||
if r, err = send(&req); err != nil {
|
||||
return
|
||||
}
|
||||
return
|
||||
return send(&req)
|
||||
}
|
||||
|
||||
type nopCloser struct {
|
||||
|
Loading…
Reference in New Issue
Block a user