From 7efd96844da89219b6fa5a9adfac4e5ff477b833 Mon Sep 17 00:00:00 2001 From: Luke Plant Date: Sat, 19 Dec 2009 14:50:41 +0000 Subject: Fixed #12251 - QuerySet.in_bulk() should accept set/frozenset Thanks to emulbreh for patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@11915 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/db/models/query.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'django') diff --git a/django/db/models/query.py b/django/db/models/query.py index 9cc7659c69..ab85bdc348 100644 --- a/django/db/models/query.py +++ b/django/db/models/query.py @@ -386,7 +386,7 @@ class QuerySet(object): """ assert self.query.can_filter(), \ "Cannot use 'limit' or 'offset' with in_bulk" - assert isinstance(id_list, (tuple, list)), \ + assert isinstance(id_list, (tuple, list, set, frozenset)), \ "in_bulk() must be provided with a list of IDs." if not id_list: return {} -- cgit v1.3