summaryrefslogtreecommitdiff
path: root/todolists/utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'todolists/utils.py')
-rw-r--r--todolists/utils.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/todolists/utils.py b/todolists/utils.py
index 0daca3b6..e86d9054 100644
--- a/todolists/utils.py
+++ b/todolists/utils.py
@@ -8,6 +8,7 @@ def todo_counts():
sql = """
SELECT todolist_id, count(*), sum(CASE WHEN status = %s THEN 1 ELSE 0 END)
FROM todolists_todolistpackage
+ WHERE removed IS NULL
GROUP BY todolist_id
"""
database = router.db_for_write(TodolistPackage)