mirror of
https://github.com/kennethreitz/requests.git
synced 2026-06-05 22:50:18 +00:00
Merge pull request #1158 from yehudasa/master
Fix check that breaks handling of 303 response in some cases (v2)
This commit is contained in:
@@ -106,7 +106,7 @@ class SessionRedirectMixin(object):
|
||||
url = urljoin(resp.url, requote_uri(url))
|
||||
|
||||
# http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.3.4
|
||||
if resp.status_code is codes.see_other and req.method != 'HEAD':
|
||||
if resp.status_code == codes.see_other and req.method != 'HEAD':
|
||||
method = 'GET'
|
||||
|
||||
# Do what the browsers do, despite standards...
|
||||
|
||||
Reference in New Issue
Block a user