We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ffd8405 commit cf05856Copy full SHA for cf05856
rest_authtoken/serializers.py
@@ -55,9 +55,10 @@ def create(self, validated_data):
55
instance.set_password(password)
56
instance.save()
57
58
- try:
59
- send_confirmation_email(instance)
60
- except SMTPException:
61
- raise ValidationError('failed to send confirmation email')
+ if REGISTRATION_EMAIL_CONFIRM:
+ try:
+ send_confirmation_email(instance)
+ except SMTPException:
62
+ raise ValidationError('failed to send confirmation email')
63
64
return instance
0 commit comments