Skip to content

Commit 72e66e4

Browse files
authored
fix minor typo (#8626)
1 parent dca4d7c commit 72e66e4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/api-guide/generic-views.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ The following attributes control the basic view behavior.
6565

6666
* `queryset` - The queryset that should be used for returning objects from this view. Typically, you must either set this attribute, or override the `get_queryset()` method. If you are overriding a view method, it is important that you call `get_queryset()` instead of accessing this property directly, as `queryset` will get evaluated once, and those results will be cached for all subsequent requests.
6767
* `serializer_class` - The serializer class that should be used for validating and deserializing input, and for serializing output. Typically, you must either set this attribute, or override the `get_serializer_class()` method.
68-
* `lookup_field` - The model field that should be used to for performing object lookup of individual model instances. Defaults to `'pk'`. Note that when using hyperlinked APIs you'll need to ensure that *both* the API views *and* the serializer classes set the lookup fields if you need to use a custom value.
68+
* `lookup_field` - The model field that should be used for performing object lookup of individual model instances. Defaults to `'pk'`. Note that when using hyperlinked APIs you'll need to ensure that *both* the API views *and* the serializer classes set the lookup fields if you need to use a custom value.
6969
* `lookup_url_kwarg` - The URL keyword argument that should be used for object lookup. The URL conf should include a keyword argument corresponding to this value. If unset this defaults to using the same value as `lookup_field`.
7070

7171
**Pagination**:
@@ -217,7 +217,7 @@ If the request data provided for creating the object was invalid, a `400 Bad Req
217217

218218
Provides a `.retrieve(request, *args, **kwargs)` method, that implements returning an existing model instance in a response.
219219

220-
If an object can be retrieved this returns a `200 OK` response, with a serialized representation of the object as the body of the response. Otherwise it will return a `404 Not Found`.
220+
If an object can be retrieved this returns a `200 OK` response, with a serialized representation of the object as the body of the response. Otherwise, it will return a `404 Not Found`.
221221

222222
## UpdateModelMixin
223223

@@ -395,4 +395,4 @@ The following third party packages provide additional generic view implementatio
395395
[UpdateModelMixin]: #updatemodelmixin
396396
[DestroyModelMixin]: #destroymodelmixin
397397
[django-rest-multiple-models]: https://github.com/MattBroach/DjangoRestMultipleModels
398-
[django-docs-select-related]: https://docs.djangoproject.com/en/3.1/ref/models/querysets/#django.db.models.query.QuerySet.select_related
398+
[django-docs-select-related]: https://docs.djangoproject.com/en/3.1/ref/models/querysets/#django.db.models.query.QuerySet.select_related

0 commit comments

Comments
 (0)