summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrian Holovaty <adrian@holovaty.com>2006-08-31 03:45:08 +0000
committerAdrian Holovaty <adrian@holovaty.com>2006-08-31 03:45:08 +0000
commit401b15d853a954c3a7c3c7d43fca0211b2252872 (patch)
treea6ce2815e32928f37cfd22d42000c263973bc023
parentfe5462e57a84f126d6e0274bb8ef9df60927345e (diff)
Fixed #2632 -- Made django.db.backends.util._dict_helper more efficient. Thanks for the patch, Andy Dustman
git-svn-id: http://code.djangoproject.com/svn/django/trunk@3684 bcc190cf-cafb-0310-a4f2-bffc1f526a37
-rw-r--r--django/db/backends/util.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/django/db/backends/util.py b/django/db/backends/util.py
index 74d33f42ca..88318941c8 100644
--- a/django/db/backends/util.py
+++ b/django/db/backends/util.py
@@ -98,7 +98,7 @@ def rev_typecast_boolean(obj, d):
def _dict_helper(desc, row):
"Returns a dictionary for the given cursor.description and result row."
- return dict([(desc[col[0]][0], col[1]) for col in enumerate(row)])
+ return dict(zip([col[0] for col in desc], row))
def dictfetchone(cursor):
"Returns a row from the cursor as a dict"