1
0
Fork 0
mirror of https://github.com/morpheus65535/bazarr synced 2025-01-01 04:26:13 +00:00

Fixed issue when trying to remove non-empty directory when cleaning leftover files after upgrade.

This commit is contained in:
morpheus65535 2021-08-06 22:11:24 -04:00
parent dd80fec9d4
commit 2cea2d22bf

View file

@ -218,7 +218,7 @@ def update_cleaner(zipfile, bazarr_dir, config_dir):
filepath = os.path.join(bazarr_dir, file)
try:
if os.path.isdir(filepath):
shutil.rmtree(filepath, ignore_errors=True)
rmtree(filepath, ignore_errors=True)
else:
os.remove(filepath)
except: