[arch-general] [PATCH 2/2] Fix indentation so ToDos get marked as "Complete"

Evangelos Foutras foutrelis at gmail.com
Sat Jan 23 18:52:17 EST 2010


The list() view was incorrectly returning from the loop that marks
ToDos as complete and thus allowing only the first ToDo to be processed.
---
 todolists/views.py |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/todolists/views.py b/todolists/views.py
index 72fed16..fb03e0c 100644
--- a/todolists/views.py
+++ b/todolists/views.py
@@ -45,8 +45,8 @@ def list(request):
     for l in lists:
         l.complete = TodolistPkg.objects.filter(
             list=l.id,complete=False).count() == 0
-        return render_to_response('todolists/list.html',
-                RequestContext(request, {'lists':lists}))
+    return render_to_response('todolists/list.html',
+        RequestContext(request, {'lists':lists}))
 
 @permission_required('main.add_todolist')
 def add(request):
-- 
1.6.6.1



More information about the arch-general mailing list