From 00444e1e56fbe82806ad50a86be40f0313acafc8 Mon Sep 17 00:00:00 2001 From: Julie Lenaerts Date: Tue, 20 Feb 2024 10:10:44 +0100 Subject: [PATCH] Add check on null value in template for closing motive --- .../Resources/views/AccompanyingCourse/index.html.twig | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourse/index.html.twig b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourse/index.html.twig index f1dbf7e89..dce01a7ee 100644 --- a/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourse/index.html.twig +++ b/src/Bundle/ChillPersonBundle/Resources/views/AccompanyingCourse/index.html.twig @@ -35,9 +35,11 @@

{{ 'This course is closed'|trans }}

-

- {{ 'Closing motive'|trans }} : {{ accompanyingCourse.closingMotive.name|localize_translatable_string }} -

+ {% if accompanyingCourse.closingMotive %} +

+ {{ 'Closing motive'|trans }} : {{ accompanyingCourse.closingMotive.name|localize_translatable_string }} +

+ {% endif %}