mirror of
				https://github.com/django/django.git
				synced 2025-10-31 09:41:08 +00:00 
			
		
		
		
	queryset-refactor: Removed an unneeded comparison to NULL for non-nullable
ForeignKey field lookups. git-svn-id: http://code.djangoproject.com/svn/django/branches/queryset-refactor@7344 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
		| @@ -934,10 +934,13 @@ class Query(object): | |||||||
|             if not merged: |             if not merged: | ||||||
|                 self.where.negate() |                 self.where.negate() | ||||||
|             if final > 1 and lookup_type != 'isnull': |             if final > 1 and lookup_type != 'isnull': | ||||||
|                 j_col = self.alias_map[alias][RHS_JOIN_COL] |                 for alias in join_list: | ||||||
|                 entry = Node([(alias, j_col, None, 'isnull', True)]) |                     if self.alias_map[alias] == self.LOUTER: | ||||||
|                 entry.negate() |                         j_col = self.alias_map[alias][RHS_JOIN_COL] | ||||||
|                 self.where.add(entry, AND) |                         entry = Node([(alias, j_col, None, 'isnull', True)]) | ||||||
|  |                         entry.negate() | ||||||
|  |                         self.where.add(entry, AND) | ||||||
|  |                         break | ||||||
|  |  | ||||||
|     def add_q(self, q_object): |     def add_q(self, q_object): | ||||||
|         """ |         """ | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user