mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix #5471 (Cannot import ePub book to 0.6.51)
This commit is contained in:
parent
24b89df761
commit
8a4f0d80a3
@ -133,11 +133,11 @@ def get_cover(opf, opf_path, stream, reader=None):
|
||||
stream.seek(0)
|
||||
zf = ZipFile(stream)
|
||||
if raster_cover:
|
||||
if reader is not None and \
|
||||
reader.encryption_meta.is_encrypted(raster_cover):
|
||||
return
|
||||
base = posixpath.dirname(opf_path)
|
||||
cpath = posixpath.normpath(posixpath.join(base, raster_cover))
|
||||
if reader is not None and \
|
||||
reader.encryption_meta.is_encrypted(cpath):
|
||||
return
|
||||
try:
|
||||
member = zf.getinfo(cpath)
|
||||
except:
|
||||
|
Loading…
x
Reference in New Issue
Block a user