diff options
author | Anton Samarchyan <anton.samarchyan@savoirfairelinux.com> | 2017-01-25 14:02:33 -0500 |
---|---|---|
committer | Tim Graham <timograham@gmail.com> | 2017-02-21 11:58:42 -0500 |
commit | 5a6f70b4281817656db2f36c5919036d38fcce7f (patch) | |
tree | 0fa649e905d960b54c5a65d80be23e42f900c23d /django/core/serializers/json.py | |
parent | 3eb679a86956d9eedf24492f0002de002f7180f5 (diff) | |
download | django-5a6f70b4281817656db2f36c5919036d38fcce7f.tar.gz |
Refs #27656 -- Updated django.core docstring verbs according to PEP 257.
Diffstat (limited to 'django/core/serializers/json.py')
-rw-r--r-- | django/core/serializers/json.py | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/django/core/serializers/json.py b/django/core/serializers/json.py index a948d87856..31f065a831 100644 --- a/django/core/serializers/json.py +++ b/django/core/serializers/json.py @@ -17,9 +17,7 @@ from django.utils.timezone import is_aware class Serializer(PythonSerializer): - """ - Convert a queryset to JSON. - """ + """Convert a queryset to JSON.""" internal_use_only = False def _init_options(self): @@ -64,9 +62,7 @@ class Serializer(PythonSerializer): def Deserializer(stream_or_string, **options): - """ - Deserialize a stream or string of JSON data. - """ + """Deserialize a stream or string of JSON data.""" if not isinstance(stream_or_string, (bytes, str)): stream_or_string = stream_or_string.read() if isinstance(stream_or_string, bytes): @@ -83,7 +79,8 @@ def Deserializer(stream_or_string, **options): class DjangoJSONEncoder(json.JSONEncoder): """ - JSONEncoder subclass that knows how to encode date/time, decimal types and UUIDs. + JSONEncoder subclass that knows how to encode date/time, decimal types, and + UUIDs. """ def default(self, o): # See "Date Time String Format" in the ECMA-262 specification. |