Update quickstart.md (#9185)

add .order_by() to eliminate Pagination UnorderedObjectListWarning
This commit is contained in:
Matt George 2024-01-04 08:10:53 -05:00 committed by GitHub
parent 530baa23cd
commit f4175b4b07
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -105,7 +105,7 @@ Right, we'd better write some views then. Open `tutorial/quickstart/views.py` a
"""
API endpoint that allows groups to be viewed or edited.
"""
queryset = Group.objects.all()
queryset = Group.objects.all().order_by('name')
serializer_class = GroupSerializer
permission_classes = [permissions.IsAuthenticated]