Permalink
Browse files

Fix POST 303 redirect resonse handling

This fixes issue #1156.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
  • Loading branch information...
1 parent 113b67c commit b07c1ebd859a32e1203c1d4ef27f1fb9e154e55e @yehudasa yehudasa committed Jan 31, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 requests/sessions.py
View
@@ -106,7 +106,7 @@ def resolve_redirects(self, resp, req, stream=False, timeout=None, verify=True,
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...

0 comments on commit b07c1eb

Please sign in to comment.