From 96a4ae33b506fce8a417bb656a6bf5af84066f13 Mon Sep 17 00:00:00 2001 From: Eraldo Energy Date: Tue, 16 Feb 2016 18:53:37 +0100 Subject: [PATCH] Environment aware registration switch setting The status of the registration (open or closed) is now read from the project environment instead of hardcoded in the common settings file. --- {{cookiecutter.repo_name}}/config/settings/common.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/{{cookiecutter.repo_name}}/config/settings/common.py b/{{cookiecutter.repo_name}}/config/settings/common.py index 0a5deebef..57e887653 100644 --- a/{{cookiecutter.repo_name}}/config/settings/common.py +++ b/{{cookiecutter.repo_name}}/config/settings/common.py @@ -213,7 +213,7 @@ ACCOUNT_EMAIL_REQUIRED = True ACCOUNT_EMAIL_VERIFICATION = 'mandatory' ACCOUNT_ADAPTER = '{{cookiecutter.repo_name}}.users.adapter.AccountAdapter' SOCIALACCOUNT_ADAPTER = '{{cookiecutter.repo_name}}.users.adapter.SocialAccountAdapter' -ACCOUNT_ALLOW_REGISTRATION = True +ACCOUNT_ALLOW_REGISTRATION = env.bool("DJANGO_ACCOUNT_ALLOW_REGISTRATION", True) # Custom user app defaults # Select the correct user model