From b2a72641300282016e7114dc464feb65b0292e0d Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sun, 27 Sep 2020 22:40:13 +0530 Subject: [PATCH] Catalog generation: Fix a regression that broke generating catalogs if books with no comments are present. Fixes #1897467 [failure to create catalog in epub format with R 5.0 and 5.01](https://bugs.launchpad.net/calibre/+bug/1897467) --- src/calibre/library/catalogs/epub_mobi_builder.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/calibre/library/catalogs/epub_mobi_builder.py b/src/calibre/library/catalogs/epub_mobi_builder.py index 383ced377e..5fdc70d5cd 100644 --- a/src/calibre/library/catalogs/epub_mobi_builder.py +++ b/src/calibre/library/catalogs/epub_mobi_builder.py @@ -2784,7 +2784,7 @@ class CatalogBuilder(object): # Comments comments = '' - if 'description' in book and book['description'] > '': + if book.get('description'): comments = book['description'] # >>>> Populate the template <<<<