Skip to content
Myr

make empty body text responses work

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

#660

authored by Kenneth Reitz · committed by Kenneth Reitz · parent e8f3fc3 · Browse files · 1 file+3 added−0 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+3 added−0 removed

  • other:+3 added−0 removed

1 file+3 added−0 removed

modified:requests/models.py+3 added
783 unmodified lines
784 # Try charset from content-type785 content = None786 encoding = self.encoding787788 if not self.content:789 return u''790791 # Fallback to auto-detected encoding.792 if self.encoding is None:793 if chardet is not None:794 encoding = chardet.detect(self.content)['encoding']
41 unmodified lines