From 60f29fc98c0b30ace8710f832799d13c73e3b1ed Mon Sep 17 00:00:00 2001 From: Andromeda Yelton Date: Tue, 1 Nov 2011 16:21:38 -0400 Subject: [PATCH] needed some exception handling --- frontend/views.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/frontend/views.py b/frontend/views.py index cbef8b43..6306650a 100755 --- a/frontend/views.py +++ b/frontend/views.py @@ -58,10 +58,13 @@ def supporter(request, supporter_username): transet = Transaction.objects.all().filter(user = supporter) for transaction in transet: - if(transaction.campaign.status == 'SUCCESSFUL'): - backed += 1 - elif(transaction.campaign.status == 'ACTIVE'): - backing += 1 + try: + if(transaction.campaign.status == 'SUCCESSFUL'): + backed += 1 + elif(transaction.campaign.status == 'ACTIVE'): + backing += 1 + except: + continue wished = supporter.wishlist.works.count()