mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-04 23:23:38 +02:00
IGN:fixes to lit2oeb
This commit is contained in:
parent
34eeb12422
commit
aa6cba1e8e
1 changed files with 5 additions and 4 deletions
|
|
@ -587,11 +587,12 @@ def _read_manifest(self):
|
|||
shared = mlist[0].path
|
||||
for item in mlist[1:]:
|
||||
path = item.path
|
||||
while not path.startswith(shared):
|
||||
shared = shared[:-1]
|
||||
if shared == '':
|
||||
while shared and not path.startswith(shared):
|
||||
try: shared = shared[:shared.rindex("/", 0, -2) + 1]
|
||||
except ValueError: shared = None
|
||||
if not shared:
|
||||
break
|
||||
else:
|
||||
if shared:
|
||||
slen = len(shared)
|
||||
for item in mlist:
|
||||
item.path = item.path[slen:]
|
||||
|
|
|
|||
Loading…
Reference in a new issue