Commit c2cfb843 by Xavier Ordoquy

Merge pull request #3971 from lynndotconfig/master

[change] using safer calling way of  "@api_view" in docs/tutorial/5-relationships-and-hyperlinked-apis.md
parents eec7c175 c3cea149
......@@ -11,7 +11,7 @@ Right now we have endpoints for 'snippets' and 'users', but we don't have a sing
from rest_framework.reverse import reverse
@api_view(('GET',))
@api_view(['GET'])
def api_root(request, format=None):
return Response({
'users': reverse('user-list', request=request, format=format),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment