mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-05 15:53:38 +02:00
Content server: Fix covers not being updated in downloaded copies of some books. Fixes #1699932 [some covers don't show up in reading apps since 3.0 update](https://bugs.launchpad.net/calibre/+bug/1699932)
This commit is contained in:
parent
50adaa402c
commit
bf99d53c80
1 changed files with 4 additions and 0 deletions
|
|
@ -200,6 +200,10 @@ def book_fmt(ctx, rd, library_id, db, book_id, fmt):
|
|||
def copy_func(dest):
|
||||
db.copy_format_to(book_id, fmt, dest)
|
||||
if update_metadata:
|
||||
if not mi.cover_data or not mi.cover_data[-1]:
|
||||
cdata = db.cover(book_id)
|
||||
if cdata:
|
||||
mi.cover_data = ('jpeg', cdata)
|
||||
set_metadata(dest, mi, fmt)
|
||||
dest.seek(0)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue