From 4fb4fc74602e87db1b6d964d45c8755019d2fed5 Mon Sep 17 00:00:00 2001 From: Oliver Falk Date: Wed, 9 May 2018 14:21:33 +0200 Subject: [PATCH] Use dummy/nobody image if no photo as been set yet (else, we raise an exception --- ivatar/ivataraccount/templates/profile.html | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ivatar/ivataraccount/templates/profile.html b/ivatar/ivataraccount/templates/profile.html index 41f981c..5877ced 100644 --- a/ivatar/ivataraccount/templates/profile.html +++ b/ivatar/ivataraccount/templates/profile.html @@ -21,7 +21,11 @@ {% for email in user.confirmedemail_set.all %}
  • {% csrf_token %} - + {% if email.photo %} + + {% else %} + Nobody + {% endif %} {{ email.email }}
    {% trans 'Change photo' %}