Bugfixes for renaming authors on gdrive

This commit is contained in:
Ozzie Isaacs 2022-02-01 20:08:42 +01:00
parent 61bfeae936
commit 0bc15636f2
3 changed files with 516 additions and 416 deletions

View File

@ -1066,7 +1066,7 @@ def upload():
book_id = db_book.id
title = db_book.title
# ToDo this currently doesn't work -> integrate in update_dir_structure_gdrive
error = helper.update_dir_structure_file(book_id,
config.config_calibre_dir,
input_authors[0],

View File

@ -464,8 +464,9 @@ def update_dir_structure_gdrive(book_id, first_author, renamed_author):
gFile = gd.getFileFromEbooksFolder(None, old_author_dir)
if gFile:
gd.moveGdriveFolderRemote(gFile, new_author_rename_dir)
else:
error = _(u'File %(file)s not found on Google Drive', file=authordir) # file not found
# author is always co-author and has is never author, no folder is okay
#else:
# error = _(u'File %(file)s not found on Google Drive', file=authordir) # file not found
else:
new_authordir = get_valid_filename(book.authors[0].name, chars=96)

File diff suppressed because it is too large Load Diff