mirror of
https://github.com/kovidgoyal/calibre.git
synced 2026-05-27 17:22:34 -04:00
Fix #7541 (Sony PRS 650 Thumbnails in wrong directory)
This commit is contained in:
@@ -199,6 +199,8 @@ class PRS505(USBMS):
|
||||
thumbnail_dir = os.path.join(prefix, *thumbnail_dir.split('/'))
|
||||
|
||||
relpath = os.path.relpath(filepath, prefix)
|
||||
if relpath.startswith('..\\'):
|
||||
relpath = relpath[3:]
|
||||
thumbnail_dir = os.path.join(thumbnail_dir, relpath)
|
||||
if not os.path.exists(thumbnail_dir):
|
||||
os.makedirs(thumbnail_dir)
|
||||
|
||||
Reference in New Issue
Block a user