diff options
author | Aymeric Augustin <aymeric.augustin@m4x.org> | 2012-08-14 14:09:23 +0200 |
---|---|---|
committer | Aymeric Augustin <aymeric.augustin@m4x.org> | 2012-08-14 14:09:23 +0200 |
commit | 9299dc42ed4986d2a1eb7c7f7fe7c276b9f6b6d6 (patch) | |
tree | 073481e4d41af108cc7bdbe822449bd4d706b7a1 /django/db/backends/mysql/compiler.py | |
parent | 2ae58b20ec72ce501c91dff8a8fcc8fe40cf5019 (diff) | |
download | django-9299dc42ed4986d2a1eb7c7f7fe7c276b9f6b6d6.tar.gz |
[py3] Removed unnecessary calls to .keys()
when computing the length of a dictionary. This fails on Python 3.
Diffstat (limited to 'django/db/backends/mysql/compiler.py')
-rw-r--r-- | django/db/backends/mysql/compiler.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/db/backends/mysql/compiler.py b/django/db/backends/mysql/compiler.py index bd4105ff8e..012bca5da6 100644 --- a/django/db/backends/mysql/compiler.py +++ b/django/db/backends/mysql/compiler.py @@ -3,7 +3,7 @@ from django.db.models.sql import compiler class SQLCompiler(compiler.SQLCompiler): def resolve_columns(self, row, fields=()): values = [] - index_extra_select = len(self.query.extra_select.keys()) + index_extra_select = len(self.query.extra_select) for value, field in map(None, row[index_extra_select:], fields): if (field and field.get_internal_type() in ("BooleanField", "NullBooleanField") and value in (0, 1)): |