From 7021e5e04791611df2e4815b223f1a7332653ed9 Mon Sep 17 00:00:00 2001
From: Robin Sonnabend <robin@fsmpi.rwth-aachen.de>
Date: Mon, 24 Jul 2017 11:04:31 +0200
Subject: [PATCH] Delete the merged todos based on their state

---
 server.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/server.py b/server.py
index a4d96dc..2699c9e 100755
--- a/server.py
+++ b/server.py
@@ -110,7 +110,7 @@ def merge_todos():
             todo1, todo2 = todo, todo_by_id[todo_id]
             print(todo1)
             print(todo2)
-            if todo2.id > todo1.id:
+            if todo2.state.value > todo1.state.value:
                 todo2, todo1 = todo1, todo2
             for protocol in todo2.protocols:
                 if protocol not in todo1.protocols:
-- 
GitLab