On 2025-08-04 21:37, Mark Sapiro wrote:
What happens if you put
```
ACCOUNT_ADAPTER = 'allauth.account.adapter.DefaultAccountAdapter'
```
in settings.py.
Hi Mark,
Putting that in the settings.py file allowed the SignUp page to display
as expected. So that was kind of back to square one.
But following the clue of "DefaultAccountAdapter" -- I edited that
adapter.py file by using your code and hey presto: success -- the SignUp
page for that one domain is now disallowed.
It's happy days.
Thank you very much for your help in cracking this little chestnut.
Best,
Mark
==========================================
@@
/opt/mailman/venv/lib/python3.11/site-packages/allauth/account/adapter.py
@@ Line 271
...
def is_open_for_signup(self, request):
"""
Checks whether or not the site is open for signups.
Next to simply returning True/False you can also intervene the
regular flow by raising an ImmediateHttpResponse
"""
- return True
+ if request.META['HTTP_HOST'] == "lists.mydomain.com":
+ return False
+ else:
+ return True
...
==========================================
_______________________________________________
Mailman-users mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/
Archived at:
https://lists.mailman3.org/archives/list/[email protected]/message/EMEKIFQKCLWMI4GSST4RBKVKWNNJW4VR/
This message sent to [email protected]