explicit exception handled for notifications retreiving

This commit is contained in:
Serghei Mihai 2014-05-14 10:35:02 +02:00
parent ac1a9bce4f
commit 3234c916a1
1 changed files with 1 additions and 1 deletions

View File

@ -25,7 +25,7 @@ class Command(BaseCommand):
notification = InvoiceNotificationEmail.objects.filter(invoice_number=invoice.id).latest()
if notification.date_sent < make_aware(datetime.now(), get_current_timezone()) - timedelta(days=notification_timeout):
continue
except:
except InvoiceNotificationEmail.DoesNotExist:
InvoiceNotificationEmail.objects.create(invoice_number=invoice.id)
nameid = invoice.famille.liaisonnameidfamille_set.all()[0]