mirror of https://github.com/morpheus65535/bazarr
Fixed issue when trying to remove non-empty directory when cleaning leftover files after upgrade.
This commit is contained in:
parent
dd80fec9d4
commit
2cea2d22bf
|
@ -218,7 +218,7 @@ def update_cleaner(zipfile, bazarr_dir, config_dir):
|
||||||
filepath = os.path.join(bazarr_dir, file)
|
filepath = os.path.join(bazarr_dir, file)
|
||||||
try:
|
try:
|
||||||
if os.path.isdir(filepath):
|
if os.path.isdir(filepath):
|
||||||
shutil.rmtree(filepath, ignore_errors=True)
|
rmtree(filepath, ignore_errors=True)
|
||||||
else:
|
else:
|
||||||
os.remove(filepath)
|
os.remove(filepath)
|
||||||
except:
|
except:
|
||||||
|
|
Loading…
Reference in New Issue