projects
/
platform
/
upstream
/
python-requests.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
340b245
)
Fixed #1711
author
daftshady
<daftonshady@gmail.com>
Tue, 29 Oct 2013 14:18:03 +0000
(23:18 +0900)
committer
daftshady
<daftonshady@gmail.com>
Tue, 26 Nov 2013 06:22:46 +0000
(15:22 +0900)
requests/sessions.py
patch
|
blob
|
history
diff --git
a/requests/sessions.py
b/requests/sessions.py
index
9c95b58
..
a5cb897
100644
(file)
--- a/
requests/sessions.py
+++ b/
requests/sessions.py
@@
-330,7
+330,11
@@
class Session(SessionRedirectMixin):
prep = self.prepare_request(req)
# Add param cookies to session cookies
- self.cookies = cookiejar_from_dict(cookies, cookiejar=self.cookies, overwrite=False)
+ if isinstance(cookies, dict):
+ self.cookies = cookiejar_from_dict(
+ cookies, cookiejar=self.cookies, overwrite=False)
+ elif isinstance(cookies, cookielib.CookieJar):
+ self.cookies.update(cookies)
proxies = proxies or {}