mirror of
https://code.eliotberriot.com/funkwhale/funkwhale.git
synced 2025-10-04 13:29:16 +02:00
15 lines
368 B
Python
15 lines
368 B
Python
from allauth.account.adapter import DefaultAccountAdapter
|
|
|
|
from django.conf import settings
|
|
|
|
|
|
class FunkwhaleAccountAdapter(DefaultAccountAdapter):
|
|
|
|
def is_open_for_signup(self, request):
|
|
|
|
if settings.REGISTRATION_MODE == "disabled":
|
|
return False
|
|
if settings.REGISTRATION_MODE == "public":
|
|
return True
|
|
|
|
return False
|