When I use
from django.conf import settings
in my DjangoRestFramework views,
class UserList(ListCreateAPIView):
queryset = settings.AUTH_USER_MODEL.objects.all()
serializer_class = UserSerializer
my I receive the error
AttributeError at /users/
'str' object has no attribute 'objects'
Request Method: GET
Request URL: http://localhost:9999/users/
Django Version: 1.5.1
Exception Type: AttributeError
Exception Value:
'str' object has no attribute 'objects'