mirror of
https://github.com/kennethreitz/requests3.git
synced 2026-06-05 23:10:16 +00:00
Remove logging and charade mention.
Logging is Not Allowed, so out it goes.
This commit is contained in:
+1
-3
@@ -725,7 +725,7 @@ class Response(object):
|
||||
if not self.encoding and len(self.content) > 3:
|
||||
# No encoding set. JSON RFC 4627 section 3 states we should expect
|
||||
# UTF-8, -16 or -32. Detect which one to use; If the detection or
|
||||
# decoding fails, fall back to `self.text` (using charade to make
|
||||
# decoding fails, fall back to `self.text` (using chardet to make
|
||||
# a best guess).
|
||||
encoding = guess_json_utf(self.content)
|
||||
if encoding is not None:
|
||||
@@ -737,8 +737,6 @@ class Response(object):
|
||||
# and the server didn't bother to tell us what codec *was*
|
||||
# used.
|
||||
pass
|
||||
log.warn('No encoding specified for JSON response, and no '
|
||||
'UTF codec detected. Falling back to charade best guess.')
|
||||
return json.loads(self.text, **kwargs)
|
||||
|
||||
@property
|
||||
|
||||
Reference in New Issue
Block a user