From 09b94fa2d2b6506d6ee75f1db5b8891d8421c958 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20Espino?= Date: Tue, 22 Jul 2014 12:41:05 +0200 Subject: [PATCH] Small guard to prevent problems with us is_closed calculation on us without status --- taiga/projects/userstories/services.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/taiga/projects/userstories/services.py b/taiga/projects/userstories/services.py index d49d2578..73dfc965 100644 --- a/taiga/projects/userstories/services.py +++ b/taiga/projects/userstories/services.py @@ -63,6 +63,9 @@ def update_userstories_order_in_bulk(bulk_data): def calculate_userstory_is_closed(user_story): + if user_story.status is None: + return False + if user_story.tasks.count() == 0: return user_story.status.is_closed