mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-09 06:53:25 +02:00
Fix bug that would raise an exception when failing to read cover information from a LIT file
This commit is contained in:
parent
4bcec54057
commit
70ee94c9b8
1 changed files with 1 additions and 2 deletions
|
|
@ -745,8 +745,7 @@ def get_metadata(stream):
|
|||
else:
|
||||
ext = ext.lower()
|
||||
cd = litfile.read_image(cover_item)
|
||||
if cd:
|
||||
mi.cover_data = (ext, cd)
|
||||
mi.cover_data = (ext, cd) if cd else (None, None)
|
||||
except:
|
||||
title = stream.name if hasattr(stream, 'name') and stream.name else 'Unknown'
|
||||
mi = MetaInformation(title, ['Unknown'])
|
||||
|
|
|
|||
Loading…
Reference in a new issue