Handle signup

This commit is contained in:
Andrew Chen Wang 2022-11-26 16:45:56 -05:00 committed by GitHub
parent e7351d8c33
commit 452009107d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -308,6 +308,12 @@ ACCOUNT_ALLOW_REGISTRATION = env.bool("DJANGO_ACCOUNT_ALLOW_REGISTRATION", True)
ACCOUNT_AUTHENTICATION_METHOD = "{{cookiecutter.username_type}}"
# https://django-allauth.readthedocs.io/en/latest/configuration.html
ACCOUNT_EMAIL_REQUIRED = True
{% if cookiecutter.username_type == "email" -%}
# https://django-allauth.readthedocs.io/en/latest/configuration.html
ACCOUNT_USERNAME_REQUIRED = False
# https://django-allauth.readthedocs.io/en/latest/configuration.html
ACCOUNT_USER_MODEL_USERNAME_FIELD = None
{% endif -%}
# https://django-allauth.readthedocs.io/en/latest/configuration.html
ACCOUNT_EMAIL_VERIFICATION = "mandatory"
# https://django-allauth.readthedocs.io/en/latest/configuration.html