From 18ab4370207cb0002915e5064c7eeee58a2b536f Mon Sep 17 00:00:00 2001 From: Radek Czajka Date: Wed, 9 Sep 2020 13:40:24 +0200 Subject: [PATCH] Bugfix for books without any text. --- src/catalogue/templates/catalogue/book_wide.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/catalogue/templates/catalogue/book_wide.html b/src/catalogue/templates/catalogue/book_wide.html index 26b085ad4..ffa4bcea1 100644 --- a/src/catalogue/templates/catalogue/book_wide.html +++ b/src/catalogue/templates/catalogue/book_wide.html @@ -7,7 +7,7 @@ {% block box-class %}book-wide-box{% endblock %} -{% block cover-link %}{% url 'book_text' book.get_first_text.slug %}{% endblock %} +{% block cover-link %}{% if book.get_first_text %}{% url 'book_text' book.get_first_text.slug %}{% endif %}{% endblock %} {% block cover-area-extra %} -- 2.20.1