mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-05 07:23:43 +02:00
Fix #299
This commit is contained in:
parent
546a402df5
commit
ebcb225613
1 changed files with 2 additions and 0 deletions
|
|
@ -368,6 +368,8 @@ def upload_books(self, files, names, on_card=False, end_session=True):
|
|||
infile.seek(0)
|
||||
name = names.next()
|
||||
paths.append(os.path.join(path, name))
|
||||
if on_card and not os.path.exists(os.path.dirname(paths[-1])):
|
||||
os.mkdir(os.path.dirname(paths[-1]))
|
||||
self.put_file(infile, paths[-1], replace_file=True)
|
||||
ctimes.append(os.path.getctime(paths[-1]))
|
||||
return zip(paths, sizes, ctimes, cycle([on_card]))
|
||||
|
|
|
|||
Loading…
Reference in a new issue