From 38e6e623cf1827ec9e43aae22d770288b4150858 Mon Sep 17 00:00:00 2001 From: Johannah Sprinz Date: Tue, 8 Feb 2022 16:51:20 +0100 Subject: hide abstract format if None --- python/fatcat_web/templates/release_view.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'python') diff --git a/python/fatcat_web/templates/release_view.html b/python/fatcat_web/templates/release_view.html index 01769b1b..4d283cbf 100644 --- a/python/fatcat_web/templates/release_view.html +++ b/python/fatcat_web/templates/release_view.html @@ -121,7 +121,9 @@ {% if release.abstracts != [] %}

Abstract

{{ release.abstracts[0].content }} -
In {{ release.abstracts[0].mimetype }} format + {%- if release.abstracts[0].mimetype != None %} +
In {{ release.abstracts[0].mimetype }} format + {% endif %} {% endif %} {% if entity.state == 'active' %} -- cgit v1.2.3 From ffa84007cbbd0740fbe94007874f29cc9257cb48 Mon Sep 17 00:00:00 2001 From: Johannah Sprinz Date: Tue, 8 Feb 2022 23:21:23 +0100 Subject: Display unknown abstract format --- python/fatcat_web/templates/release_view.html | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'python') diff --git a/python/fatcat_web/templates/release_view.html b/python/fatcat_web/templates/release_view.html index 4d283cbf..55c45222 100644 --- a/python/fatcat_web/templates/release_view.html +++ b/python/fatcat_web/templates/release_view.html @@ -121,9 +121,13 @@ {% if release.abstracts != [] %}

Abstract

{{ release.abstracts[0].content }} - {%- if release.abstracts[0].mimetype != None %} -
In {{ release.abstracts[0].mimetype }} format - {% endif %} +
+ {%- if release.abstracts[0].mimetype != None %} + In {{ release.abstracts[0].mimetype }} format + {% else %} + Unknown format + {% endif %} + {% endif %} {% if entity.state == 'active' %} -- cgit v1.2.3