You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For backwards compatibility reasons, we should keep redirecting HEAD as HEAD. There is no harm in preserving this old behavior since the RFC doesn't specify that methods must be set to GET for 301, 302, and 303 redirect.
Commit 7db996e alters the behavior of redirects with the
HEAD
method unnecessarily.The logic in Go1.7 had the following properties:
GET
,HEAD
,PUT
,POST
methods only.PUT
orPOST
, it would convert it to be theGET
method.GET
exceptHEAD
, which continued to be redirected asHEAD
.The logic in Go1.8 has the following properties:
GET
.For backwards compatibility reasons, we should keep redirecting
HEAD
asHEAD
. There is no harm in preserving this old behavior since the RFC doesn't specify that methods must be set toGET
for 301, 302, and 303 redirect.Reproducer: https://play.golang.org/p/kKuGNRjHV9
\cc @bradfitz @odeke-em
The text was updated successfully, but these errors were encountered: