From c4b82a9db88cc9e3f73468901a398a58989550bb Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sun, 26 Jan 2014 09:21:31 +0530 Subject: [PATCH] Edit book: Fix cover not being updated from the current cover in the calibre library when using Edit Book. Note that you can turn off metadata updating via Preferences->calibre Integration in Edit Book. Fixes #1272730 [[enhancement] add selected cover to book](https://bugs.launchpad.net/calibre/+bug/1272730) --- src/calibre/gui2/actions/tweak_epub.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/calibre/gui2/actions/tweak_epub.py b/src/calibre/gui2/actions/tweak_epub.py index 80de8fe4f8..375917c620 100755 --- a/src/calibre/gui2/actions/tweak_epub.py +++ b/src/calibre/gui2/actions/tweak_epub.py @@ -132,7 +132,7 @@ class TweakEpubAction(InterfaceAction): if tprefs['update_metadata_from_calibre']: from calibre.ebooks.metadata.opf2 import pretty_print from calibre.ebooks.metadata.meta import set_metadata - mi = db.new_api.get_metadata(book_id) + mi = db.new_api.get_metadata(book_id, get_cover=True) with pretty_print, open(path, 'r+b') as f: set_metadata(f, mi, stream_type=fmt.lower()) notify = '%d:%s:%s:%s' % (book_id, fmt, db.library_id, db.library_path)