Django

Code

Changeset 3684

Show
Ignore:
Timestamp:
08/30/06 22:45:08 (2 years ago)
Author:
adrian
Message:

Fixed #2632 -- Made django.db.backends.util._dict_helper more efficient. Thanks for the patch, Andy Dustman

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/django/db/backends/util.py

    r3113 r3684  
    9999def _dict_helper(desc, row): 
    100100    "Returns a dictionary for the given cursor.description and result row." 
    101     return dict([(desc[col[0]][0], col[1]) for col in enumerate(row)]
     101    return dict(zip([col[0] for col in desc], row)
    102102 
    103103def dictfetchone(cursor):