I define a custom User model:

```
from django.contrib.auth.models import AbstractUser

class CustomUser(AbstractUser):
   somefield = models.CharField(max_length=60)

```

and I add AUTH\_USER\_MODEL to settengs :

```
AUTH_USER_MODEL = 'userm.CustomUser'

```

but when I try this command the authenticate function return None:

```
In [36]: from django.contrib.auth import authenticate

In [37]: CustomUser.objects.create(username='root',password='root')
Out[37]: <CustomUser: root>

In [38]: authenticate(username='root', password='root')

```

and the result of objects.all is:

```
In [47]: CustomUser.objects.all()
Out[47]: [<CustomUser: admin>, <CustomUser: nima>, <CustomUser: ali>, <CustomUser: root>, <CustomUser: esi>, <CustomUser: sha>]

```

am I missed something??