-
Notifications
You must be signed in to change notification settings - Fork 150
Added reset by phone number functionality #74
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
Added reset by phone number functionality #74
Conversation
|
||
def validate(self, attrs): | ||
if not attrs.get("email") and not attrs.get("phone"): | ||
raise serializers.ValidationError('Please provide Email or Phone Number') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This message doesn't make clear for user which fields needs to be provided. phone? phone_number?
-raise serializers.ValidationError('Please provide Email or Phone Number')
+raise serializers.ValidationError('Please provide email or phone field')
Thanks for the PR! It would be convenient to pass the authentication method (email or phone) to the signal's receiver. |
What would be really nice is the ability to define a custom serializer extending the library. For instance in our case we need to identify the user by VAT number. |
Exactly this approach is what I was hoping for #93 @peterolayinka this would allow you to use phone number |
@enricostano sounds good to me! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi Guys, Thanks for the review, I totally missed this conversation. I guess this is due to plenty of work-related emails from GitHub. |
@Morantron do we still need this? |
yep |
@anx-hnezbeda do you mind keeping this issue open? Thanks! |
@Morantron @enricostano what approach would you prefer to have this merged? Though, I made a fork already which I use in my codebase. |
Problem
This package is limited to recovering passwords by email only leaving out use case for where we have users signup with phone number.
solution
Added functionality to recover passwords by phone number.