Change User model in BaseUserCreationForm/UserChangeForm.Meta to get_user_model().
Please Change standart User model in BaseUserCreationForm.Meta in django.contrib.auth.forms to get_user_model()
class BaseUserCreationForm(forms.ModelForm):
class Meta:
model = get_user_model()
fields = ("username",)
field_classes = {"username": UsernameField}
Change History
(2)
Resolution: |
→ duplicate
|
Status: |
new → closed
|
Type: |
Cleanup/optimization → New feature
|
Summary: |
Change standart User model in BaseUserCreationForm.Meta and UserChangeForm.Meta in django.contrib.auth.forms to get_user_model() → Change User model in BaseUserCreationForm/UserChangeForm.Meta to get_user_model().
|
Duplicate of #19353.