Skip to content

Commit 5ee970c

Browse files
chrisguoxrpkilby
authored andcommitted
Fix docs typos (encode#7015)
1 parent c9f06bf commit 5ee970c

File tree

7 files changed

+14
-14
lines changed

7 files changed

+14
-14
lines changed

docs/api-guide/fields.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -713,7 +713,7 @@ the coordinate pair:
713713
fields = ['label', 'coordinates']
714714

715715
Note that this example doesn't handle validation. Partly for that reason, in a
716-
real project, the coordinate nesting might be better handled with a nested serialiser
716+
real project, the coordinate nesting might be better handled with a nested serializer
717717
using `source='*'`, with two `IntegerField` instances, each with their own `source`
718718
pointing to the relevant field.
719719

@@ -746,7 +746,7 @@ suitable for updating our target object. With `source='*'`, the return from
746746
('y_coordinate', 4),
747747
('x_coordinate', 3)])
748748

749-
For completeness lets do the same thing again but with the nested serialiser
749+
For completeness lets do the same thing again but with the nested serializer
750750
approach suggested above:
751751

752752
class NestedCoordinateSerializer(serializers.Serializer):
@@ -768,14 +768,14 @@ declarations. It's our `NestedCoordinateSerializer` that takes `source='*'`.
768768
Our new `DataPointSerializer` exhibits the same behaviour as the custom field
769769
approach.
770770

771-
Serialising:
771+
Serializing:
772772

773773
>>> out_serializer = DataPointSerializer(instance)
774774
>>> out_serializer.data
775775
ReturnDict([('label', 'testing'),
776776
('coordinates', OrderedDict([('x', 1), ('y', 2)]))])
777777

778-
Deserialising:
778+
Deserializing:
779779

780780
>>> in_serializer = DataPointSerializer(data=data)
781781
>>> in_serializer.is_valid()
@@ -802,8 +802,8 @@ But we also get the built-in validation for free:
802802
{'x': ['A valid integer is required.'],
803803
'y': ['A valid integer is required.']})])
804804

805-
For this reason, the nested serialiser approach would be the first to try. You
806-
would use the custom field approach when the nested serialiser becomes infeasible
805+
For this reason, the nested serializer approach would be the first to try. You
806+
would use the custom field approach when the nested serializer becomes infeasible
807807
or overly complex.
808808

809809

docs/api-guide/requests.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ If a client sends a request with a content-type that cannot be parsed then a `Un
4949

5050
# Content negotiation
5151

52-
The request exposes some properties that allow you to determine the result of the content negotiation stage. This allows you to implement behaviour such as selecting a different serialisation schemes for different media types.
52+
The request exposes some properties that allow you to determine the result of the content negotiation stage. This allows you to implement behaviour such as selecting a different serialization schemes for different media types.
5353

5454
## .accepted_renderer
5555

docs/api-guide/schemas.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ for each view, allowed method, and path.
176176
**Note**: For basic `APIView` subclasses, default introspection is essentially
177177
limited to the URL kwarg path parameters. For `GenericAPIView`
178178
subclasses, which includes all the provided class based views, `AutoSchema` will
179-
attempt to introspect serialiser, pagination and filter fields, as well as
179+
attempt to introspect serializer, pagination and filter fields, as well as
180180
provide richer path field descriptions. (The key hooks here are the relevant
181181
`GenericAPIView` attributes and methods: `get_serializer`, `pagination_class`,
182182
`filter_backends` and so on.)

docs/community/release-notes.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -222,11 +222,11 @@ Be sure to upgrade to Python 3 before upgrading to Django REST Framework 3.10.
222222
def perform_create(self, serializer):
223223
serializer.save(owner=self.request.user)
224224

225-
Alternatively you may override `save()` or `create()` or `update()` on the serialiser as appropriate.
225+
Alternatively you may override `save()` or `create()` or `update()` on the serializer as appropriate.
226226

227227
* Correct allow_null behaviour when required=False [#5888][gh5888]
228228

229-
Without an explicit `default`, `allow_null` implies a default of `null` for outgoing serialisation. Previously such
229+
Without an explicit `default`, `allow_null` implies a default of `null` for outgoing serialization. Previously such
230230
fields were being skipped when read-only or otherwise not required.
231231

232232
**Possible backwards compatibility break** if you were relying on such fields being excluded from the outgoing
@@ -464,7 +464,7 @@ Be sure to upgrade to Python 3 before upgrading to Django REST Framework 3.10.
464464
* Deprecated `exclude_from_schema` on `APIView` and `api_view` decorator. Set `schema = None` or `@schema(None)` as appropriate. [#5422][gh5422]
465465
* Timezone-aware `DateTimeField`s now respect active or default `timezone` during serialization, instead of always using UTC. [#5435][gh5435]
466466

467-
Resolves inconsistency whereby instances were serialised with supplied datetime for `create` but UTC for `retrieve`. [#3732][gh3732]
467+
Resolves inconsistency whereby instances were serialized with supplied datetime for `create` but UTC for `retrieve`. [#3732][gh3732]
468468

469469
**Possible backwards compatibility break** if you were relying on datetime strings being UTC. Have client interpret datetimes or [set default or active timezone (docs)][djangodocs-set-timezone] to UTC if needed.
470470

docs/community/third-party-packages.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -254,7 +254,7 @@ To submit new content, [open an issue][drf-create-issue] or [create a pull reque
254254
### Misc
255255

256256
* [cookiecutter-django-rest][cookiecutter-django-rest] - A cookiecutter template that takes care of the setup and configuration so you can focus on making your REST apis awesome.
257-
* [djangorestrelationalhyperlink][djangorestrelationalhyperlink] - A hyperlinked serialiser that can can be used to alter relationships via hyperlinks, but otherwise like a hyperlink model serializer.
257+
* [djangorestrelationalhyperlink][djangorestrelationalhyperlink] - A hyperlinked serializer that can can be used to alter relationships via hyperlinks, but otherwise like a hyperlink model serializer.
258258
* [django-rest-swagger][django-rest-swagger] - An API documentation generator for Swagger UI.
259259
* [django-rest-framework-proxy][django-rest-framework-proxy] - Proxy to redirect incoming request to another API server.
260260
* [gaiarestframework][gaiarestframework] - Utils for django-rest-framework

docs/coreapi/schemas.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ each view, allowed method and path.)
191191
**Note**: For basic `APIView` subclasses, default introspection is essentially
192192
limited to the URL kwarg path parameters. For `GenericAPIView`
193193
subclasses, which includes all the provided class based views, `AutoSchema` will
194-
attempt to introspect serialiser, pagination and filter fields, as well as
194+
attempt to introspect serializer, pagination and filter fields, as well as
195195
provide richer path field descriptions. (The key hooks here are the relevant
196196
`GenericAPIView` attributes and methods: `get_serializer`, `pagination_class`,
197197
`filter_backends` and so on.)

tests/test_serializer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -555,7 +555,7 @@ class Serializer(serializers.Serializer):
555555
bar = serializers.CharField(source='foo.bar', allow_null=True)
556556
optional = serializers.CharField(required=False, allow_null=True)
557557

558-
# allow_null=True should imply default=None when serialising:
558+
# allow_null=True should imply default=None when serializing:
559559
assert Serializer({'foo': None}).data == {'foo': None, 'bar': None, 'optional': None, }
560560

561561

0 commit comments

Comments
 (0)