diff options
| author | Cory Benfield <lukasaoz@gmail.com> | 2015-05-13 07:04:57 +0100 |
|---|---|---|
| committer | Cory Benfield <lukasaoz@gmail.com> | 2015-05-14 20:58:20 +0100 |
| commit | fb6dade63d967623e5fb7505e05d22995dcec00e (patch) | |
| tree | 7f85bc4936a7f41ff9988adefb2473c581ddfc5e /requests/models.py | |
| parent | 868625532d2c64e4a46ec05a5c74bebff90c62e7 (diff) | |
| download | python-requests-fb6dade63d967623e5fb7505e05d22995dcec00e.tar.gz | |
Partially revert ab84f9be5740d4649d734e73b84f17f85e52ffc9
Diffstat (limited to 'requests/models.py')
| -rw-r--r-- | requests/models.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/requests/models.py b/requests/models.py index f32dd5f6..152cb519 100644 --- a/requests/models.py +++ b/requests/models.py @@ -30,7 +30,8 @@ from .utils import ( iter_slices, guess_json_utf, super_len, to_native_string) from .compat import ( cookielib, urlunparse, urlsplit, urlencode, str, bytes, StringIO, - is_py2, chardet, json, builtin_str, basestring) + is_py2, chardet, builtin_str, basestring) +from .compat import json as complexjson from .status_codes import codes #: The set of HTTP status codes that indicate an automatically @@ -415,7 +416,7 @@ class PreparedRequest(RequestEncodingMixin, RequestHooksMixin): if json is not None: content_type = 'application/json' - body = json.dumps(json) + body = complexjson.dumps(json) is_stream = all([ hasattr(data, '__iter__'), |
