From 22dcf032cc62db7c19fe60d3afdf1aa7c9333f71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Barrag=C3=A1n=20Merino?= Date: Tue, 4 Feb 2014 17:39:16 +0100 Subject: [PATCH] Bug #140 fixed --- taiga/projects/aggregates/filters.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/taiga/projects/aggregates/filters.py b/taiga/projects/aggregates/filters.py index 9bee00e0..f749c116 100644 --- a/taiga/projects/aggregates/filters.py +++ b/taiga/projects/aggregates/filters.py @@ -85,7 +85,7 @@ def _get_issues_assigned_to(project): UNION select user_id, (select count(*) from issues_issue where project_id = pm.project_id and assigned_to_id = pm.user_id) from projects_membership as pm - where project_id = %s; + where project_id = %s and pm.user_id is not null; """ with closing(connection.cursor()) as cursor: @@ -100,7 +100,7 @@ def _get_issues_owners(project): select user_id, (select count(*) from issues_issue where project_id = pm.project_id and owner_id = pm.user_id) from projects_membership as pm - where project_id = %s; + where project_id = %s and pm.user_id is not null; """ with closing(connection.cursor()) as cursor: