kopia lustrzana https://dev.funkwhale.audio/funkwhale/funkwhale
16 wiersze
368 B
Python
16 wiersze
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
|