DJ1.9 compat field.related

This commit is contained in:
Marc Aymerich 2016-04-28 10:41:22 +00:00
parent b89440a8f3
commit 0b126a5bf8
1 changed files with 1 additions and 1 deletions

View File

@ -19,7 +19,7 @@ def create_initial_superuser(**kwargs):
) )
from ..models import Account from ..models import Account
try: try:
Account.systemusers.related.model.objects.filter(account_id=1).exists() Account.systemusers.field.related.model.objects.filter(account_id=1).exists()
except FieldError: except FieldError:
# avoid creating a systemuser when systemuser table is not ready # avoid creating a systemuser when systemuser table is not ready
Account.save = models.Model.save Account.save = models.Model.save