Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/develop' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
Kenneth Reitz committed Feb 28, 2012
2 parents ab0714c + a3a7c50 commit 65eaebb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions AUTHORS.rst
Expand Up @@ -84,3 +84,4 @@ Patches and Suggestions
- Matt Giuca
- Adam Tauber
- Honza Javorek
- Brendan Maguire <maguire.brendan@gmail.com>
3 changes: 3 additions & 0 deletions requests/sessions.py
Expand Up @@ -64,6 +64,7 @@ def __init__(self,
hooks=None,
params=None,
config=None,
prefetch=False,
verify=True):

self.headers = headers or {}
Expand All @@ -74,6 +75,7 @@ def __init__(self,
self.hooks = hooks or {}
self.params = params or {}
self.config = config or {}
self.prefetch = prefetch
self.verify = verify

for (k, v) in list(defaults.items()):
Expand Down Expand Up @@ -148,6 +150,7 @@ def request(self, method, url,
headers = {} if headers is None else headers
params = {} if params is None else params
hooks = {} if hooks is None else hooks
prefetch = self.prefetch or prefetch

# use session's hooks as defaults
for key, cb in list(self.hooks.items()):
Expand Down

0 comments on commit 65eaebb

Please sign in to comment.