Skip to content
Myr

explaining

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Kenneth Reitz · committed by Kenneth Reitz · parent a699ddd · Browse files · 1 file+8 added−5 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+8 added−5 removed

  • other:+8 added−5 removed

1 file+8 added−5 removed

modified:requests/models.py+8 added-5 removed
120 unmodified lines
121122 def build(resp):123124 response = Response()125126 # Pass settings over.127 response.config = self.config128129 # Fallback to None if there's no staus_code, for whatever reason.130 response.status_code = getattr(resp, 'status', None)131128 try:129 response.headers = CaseInsensitiveDict(getattr(resp, 'headers', None))130 response.raw = resp132 # Make headers case-insensitive.133 response.headers = CaseInsensitiveDict(getattr(resp, 'headers', None))134132 except AttributeError:133 pass135 # Save original resopnse for later.136 response.raw = resp137138 if is_error:139 response.error = resp140
299 unmodified lines