Skip to content
This repository has been archived by the owner on Oct 10, 2022. It is now read-only.

Commit

Permalink
Replaced use of delete_file() in process_failed_fragments() with dele…
Browse files Browse the repository at this point in the history
…te_file_by_id(). This error was likely left over from the refactoring that was done as part of the v1.0.20 release.
  • Loading branch information
DavidBerdik committed Jun 23, 2020
1 parent 4ba2ab4 commit 88352b7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libs/upload_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,11 +90,11 @@ def process_failed_fragments(drive_api, failed_fragments, dir_id, debug_log):
debug_log.write(" Validity check disabled\n")
else:
# If the hashes do not match, delete the fragment.
drive_api.delete_file(drive_api.get_service(), file['id'])
drive_api.delete_file_by_id(drive_api.get_service(), file['id'])
debug_log.write(" Removed corrupt duplicate with ID " + file['id'] + " | checkDataValidity = True\n")
else:
# If we should not check data validity, delete the file.
drive_api.delete_file(drive_api.get_service(), file['id'])
drive_api.delete_file_by_id(drive_api.get_service(), file['id'])
debug_log.write(" Removed corrupt duplicate with ID " + file['id'] + " | checkDataValidity = False\n")

debug_log.write("Processing of detected corruption completed.\n")
Expand Down

0 comments on commit 88352b7

Please sign in to comment.