diff options
Diffstat (limited to 'django/contrib/contenttypes/management.py')
| -rw-r--r-- | django/contrib/contenttypes/management.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/django/contrib/contenttypes/management.py b/django/contrib/contenttypes/management.py index 6a23ef5287..1b1c9c8562 100644 --- a/django/contrib/contenttypes/management.py +++ b/django/contrib/contenttypes/management.py @@ -1,6 +1,7 @@ from django.contrib.contenttypes.models import ContentType from django.db.models import get_apps, get_models, signals from django.utils.encoding import smart_unicode +from django.utils import six def update_contenttypes(app, created_models, verbosity=2, **kwargs): """ @@ -24,7 +25,7 @@ def update_contenttypes(app, created_models, verbosity=2, **kwargs): ) to_remove = [ ct - for (model_name, ct) in content_types.iteritems() + for (model_name, ct) in six.iteritems(content_types) if model_name not in app_models ] @@ -34,7 +35,7 @@ def update_contenttypes(app, created_models, verbosity=2, **kwargs): app_label=app_label, model=model_name, ) - for (model_name, model) in app_models.iteritems() + for (model_name, model) in six.iteritems(app_models) if model_name not in content_types ]) if verbosity >= 2: |
