mirror of
https://github.com/encode/django-rest-framework.git
synced 2024-11-22 09:36:49 +03:00
Merge pull request #5350 from qwhex/patch-1
Update 2-requests-and-responses.md: consistency
This commit is contained in:
commit
698d8b7507
|
@ -47,7 +47,7 @@ We don't need our `JSONResponse` class in `views.py` anymore, so go ahead and de
|
|||
@api_view(['GET', 'POST'])
|
||||
def snippet_list(request):
|
||||
"""
|
||||
List all snippets, or create a new snippet.
|
||||
List all code snippets, or create a new snippet.
|
||||
"""
|
||||
if request.method == 'GET':
|
||||
snippets = Snippet.objects.all()
|
||||
|
@ -68,7 +68,7 @@ Here is the view for an individual snippet, in the `views.py` module.
|
|||
@api_view(['GET', 'PUT', 'DELETE'])
|
||||
def snippet_detail(request, pk):
|
||||
"""
|
||||
Retrieve, update or delete a snippet instance.
|
||||
Retrieve, update or delete a code snippet.
|
||||
"""
|
||||
try:
|
||||
snippet = Snippet.objects.get(pk=pk)
|
||||
|
|
Loading…
Reference in New Issue
Block a user