-
Notifications
You must be signed in to change notification settings - Fork 148
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FEATURE] error message for is_active=False user #160
Comments
from rest_framework.decorators import api_view
from rest_framework.response import Response
@api_view()
def hello_world(request):
if request.user.is_active:
return Response({"message": "Hello, world!"})
return Response({"message": "Not hello, world!"})
? |
This library for some reason decides that if a user isn't active it just won't ever send an email out and it does this by monkey patching the user model to expose a new function I don't know if this is the best or most elegant fix, but you can monkey patch it back out. A env setting to allow inactive users to have password resets would be so much better.
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Does anyone know how to extend the APIVIew to return more accurate messages for is_active=False users?
The text was updated successfully, but these errors were encountered: