Skip to content

Commit

Permalink
don't double decode
Browse files Browse the repository at this point in the history
  • Loading branch information
Kenneth Reitz committed Jan 22, 2012
1 parent b725bfd commit 2c7e920
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion requests/models.py
Expand Up @@ -752,7 +752,8 @@ def text(self):

# Try to fall back:
try:
content = unicode(content, encoding, errors='replace')
if not content:
content = unicode(content, encoding, errors='replace')
except UnicodeError, TypeError:
pass

Expand Down

0 comments on commit 2c7e920

Please sign in to comment.