fix for python 3

This commit is contained in:
2017-05-26 22:08:46 -04:00
parent 60b9fb17af
commit 8c2a36140b
+1 -1
View File
@@ -674,7 +674,7 @@ class Session(SessionRedirectMixin):
# If redirects aren't being followed, store the response on the Request for Response.next().
if not allow_redirects:
try:
r._next = self.resolve_redirects(r, request, yield_requests=True, **kwargs).next()
r._next = next(self.resolve_redirects(r, request, yield_requests=True, **kwargs))
except StopIteration:
pass