Django registration - allows multiple users email id

I am trying to do django-registration. I found that it allows multiple registration for the same email. I want to prevent this. What is the best way to do this?

ok, I see that there is a subclass of RegistrationFormUniqueEmail. Now how to use this class? I changed this

    def get_form_class(self, request):

    return RegistrationFormUniqueEmail

But it might be better to change this from my application and not into the source code. So how do I do this? thank

+3
source share
1 answer

Once you have added registrationsettings to your file, you can use the form in your views.py, for example:

from registration.forms import RegistrationFormUniqueEmail

form = RegistrationFormUniqueEmail()

. , , .

+2

Source: https://habr.com/ru/post/1788760/


All Articles