Skip to content

Commit

Permalink
Change hard-coded User to settings.AUTH_USER_MODEL (#5)
Browse files Browse the repository at this point in the history
* Change hard-coded User to settings.AUTH_USER_MODEL
  • Loading branch information
JakeAustwick authored and abhishek776 committed Mar 16, 2017
1 parent eeca677 commit 22326fa
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions deux/abstract_models.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

from binascii import unhexlify

from django.contrib.auth.models import User
from django.conf import settings
from django.db import models
from django.utils.crypto import constant_time_compare

Expand All @@ -28,7 +28,8 @@ class AbstractMultiFactorAuth(models.Model):

#: User this MFA object represents.
user = models.OneToOneField(
User, related_name="multi_factor_auth", primary_key=True)
settings.AUTH_USER_MODEL, related_name="multi_factor_auth",
primary_key=True)

#: User's phone number.
phone_number = models.CharField(
Expand Down

0 comments on commit 22326fa

Please sign in to comment.