From 1ac959623eadbc400f3d3b151a92b6b636a5ccaf Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Mon, 17 Nov 2014 16:56:53 +0000 Subject: [PATCH] fix #2570 --- pandora/item/managers.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pandora/item/managers.py b/pandora/item/managers.py index f4ff2bad..50676820 100644 --- a/pandora/item/managers.py +++ b/pandora/item/managers.py @@ -132,7 +132,7 @@ def parseCondition(condition, user, owner=None): elif key_type == 'boolean': q = Q(**{'find__key': k, 'find__value': v}) if exclude: - q = ~q + q = ~Q(id__in=models.Item.objects.filter(q)) return q elif key_type == "string": in_find = not k.startswith('public_id') @@ -158,7 +158,7 @@ def parseCondition(condition, user, owner=None): else: q = Q(**{value_key: v}) if exclude: - q = ~q + q = ~Q(id__in=models.Item.objects.filter(q)) return q elif k == 'list': q = Q(id=0)