My django project is working with a third-party forum. The activation_email is being send through get_current_site(request)
.
The password rest is done by a django built called password_reset
from django.contrib.auth.views import
.
For another app I needed to install django.contrib.sites
. Through that get_current_site(request)
does not give me the current site, but "example.com" from django.contrib.sites.models
. The problem is:
- the activation mails does have the wrong domain (example.com)
- when I change the activation_mail sender in the code, the passwort reset mail still comes with "example.com" because it is using the django built_in way.
My project is online already. So I thought I can delete example.com and add my domain-name. But now I can not sign in anymore and this error occurs:
django.contrib.sites.models.DoesNotExist: Site matching query does not exist.