Ensure that our splay query cannot fail on DoesNotExist
@@ -37,7 +37,11 @@ class NotificationUser(NotificationBase):
form = FormUser
def splay(self, address):
+ try:
user = User.objects.get(username=address)
+ except User.DoesNotExist:
+ logger.error("Missing user %s", address)
+ else:
for sender in models.Sender.objects.filter(obj=user):
yield sender
