From a0d15ccec0608555dcdb03c29bd18d60d5869948 Mon Sep 17 00:00:00 2001 From: mattkatz Date: Sun, 14 Apr 2024 04:55:45 -0400 Subject: [PATCH] Don't show a colon if there is no author_text If there is no author for a book, render just the title of the book. --- bookwyrm/views/rss_feed.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bookwyrm/views/rss_feed.py b/bookwyrm/views/rss_feed.py index b1487c9d5..e5be10b1c 100644 --- a/bookwyrm/views/rss_feed.py +++ b/bookwyrm/views/rss_feed.py @@ -188,7 +188,10 @@ class RssShelfFeed(Feed): def item_title(self, item): """render the item title""" authors = item.authors - authors.display_name = f"{item.author_text}:" + if item.author_text: + authors.display_name = f"{item.author_text}:" + else: + authors.description = "" template = get_template("rss/title.html") return template.render({"user": authors, "item_title": item.title}).strip()