Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed #15283 -- Made a minor performance tweak to __iter__. Thanks to…

… lanyjie for the report.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@15491 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 337a6bc0f61fd3f72f1e2cacbb3bb5821028e44f 1 parent b01cc1b
@freakboy3742 freakboy3742 authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  django/db/models/query.py
View
2  django/db/models/query.py
@@ -81,7 +81,7 @@ def __len__(self):
else:
self._result_cache = list(self.iterator())
elif self._iter:
- self._result_cache.extend(list(self._iter))
+ self._result_cache.extend(self._iter)
return len(self._result_cache)
def __iter__(self):
Please sign in to comment.
Something went wrong with that request. Please try again.