From 699dbc0c553c551f1a1c106303b6a08aa9212b68 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 15 May 2014 15:37:02 +0530 Subject: [PATCH] Book polishing: Fix publisher field in epub not being cleared when updating metadata. Fixes #1319732 [calibre will not update Publisher](https://bugs.launchpad.net/calibre/+bug/1319732) --- src/calibre/ebooks/metadata/epub.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/calibre/ebooks/metadata/epub.py b/src/calibre/ebooks/metadata/epub.py index e0a8d8d567..6b57879ee2 100644 --- a/src/calibre/ebooks/metadata/epub.py +++ b/src/calibre/ebooks/metadata/epub.py @@ -274,6 +274,8 @@ def update_metadata(opf, mi, apply_null=False, update_timestamp=False, force_ide opf.isbn = None if not getattr(mi, 'comments', None): opf.comments = None + if not getattr(mi, 'publisher', None): + opf.publisher = None if apply_null or force_identifiers: opf.set_identifiers(mi.get_identifiers()) else: