Skip to content

Commit

Permalink
use queryset in resend email verification view (#548)
Browse files Browse the repository at this point in the history
  • Loading branch information
mohammad330a authored Sep 17, 2023
1 parent 5dfc876 commit f172ded
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dj_rest_auth/registration/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ def create(self, request, *args, **kwargs):
serializer = self.get_serializer(data=request.data)
serializer.is_valid(raise_exception=True)

email = EmailAddress.objects.filter(**serializer.validated_data).first()
email = self.get_queryset().filter(**serializer.validated_data).first()
if email and not email.verified:
email.send_confirmation(request)

Expand Down

0 comments on commit f172ded

Please sign in to comment.