From 9bdec6338e34451d04e0f9207e6aa90f35d3217d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julien=20Fastr=C3=A9?= Date: Tue, 5 Jun 2018 11:43:20 +0200 Subject: [PATCH] fix error when birthdate == null --- Resources/views/Person/create_review.html.twig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Resources/views/Person/create_review.html.twig b/Resources/views/Person/create_review.html.twig index eed4d57b2..22e51ae27 100644 --- a/Resources/views/Person/create_review.html.twig +++ b/Resources/views/Person/create_review.html.twig @@ -51,7 +51,7 @@ {% endspaceless %} - {{ person.birthdate|localizeddate('long', 'none', app.request.locale) }} + {% if person.birthdate is not null %}{{ person.birthdate|localizeddate('long', 'none', app.request.locale) }}{% else %} {% endif %} {% if person.nationality is not null %}{{ person.nationality.name|localize_translatable_string }}{% else %}{{ 'Without nationality'|trans }}{% endif %}