From 8b52e8e40e100f02f09138947fee706c00c3ccbc Mon Sep 17 00:00:00 2001 From: Malcolm Tredinnick Date: Tue, 18 Mar 2008 10:21:12 +0000 Subject: [PATCH] queryset-refactor: Removed the facility for select_related(False). It was useless. git-svn-id: http://code.djangoproject.com/svn/django/branches/queryset-refactor@7284 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/db/models/query.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/django/db/models/query.py b/django/db/models/query.py index 1c5c3aa0db..5cbaf9d5ff 100644 --- a/django/db/models/query.py +++ b/django/db/models/query.py @@ -381,8 +381,6 @@ class _QuerySet(object): related objects are included in the selection. """ depth = kwargs.pop('depth', 0) - # TODO: Remove this? select_related(False) isn't really useful. - true_or_false = kwargs.pop('true_or_false', True) if kwargs: raise TypeError('Unexpected keyword arguments to select_related: %s' % (kwargs.keys(),)) @@ -392,7 +390,7 @@ class _QuerySet(object): raise TypeError('Cannot pass both "depth" and fields to select_related()') obj.query.add_select_related(fields) else: - obj.query.select_related = true_or_false + obj.query.select_related = True if depth: obj.query.max_depth = depth return obj