Mailman: split the django_fedora module

Some imports need to read the config file, which creates a import loop.
This commit is contained in:
Aurélien Bompard 2017-07-21 09:05:04 +00:00
parent a7a67a72ef
commit f40ce9d969
4 changed files with 24 additions and 23 deletions

View file

@ -13,19 +13,3 @@ def exclude_useless_errors(record):
if isinstance(exc_value, excluded_class):
return False
return True
# Disable local signup
from allauth.account.adapter import DefaultAccountAdapter
from allauth.socialaccount.adapter import DefaultSocialAccountAdapter
class NoLocalSignUpAdapter(DefaultAccountAdapter):
def is_open_for_signup(self, request):
return False
class SignUpEnabledSocialAdapter(DefaultSocialAccountAdapter):
def is_open_for_signup(self, request, sociallogin):
return True