mirror of
https://github.com/tuna/tunasync-scripts.git
synced 2025-04-20 04:12:42 +00:00
Python 3.7 compatible
This commit is contained in:
parent
2c651021e4
commit
d204e3aa7f
@ -417,8 +417,14 @@ def garbage_collect():
|
|||||||
|
|
||||||
if DELETE_OLD:
|
if DELETE_OLD:
|
||||||
narinfo = parse_narinfo(path.read_text())
|
narinfo = parse_narinfo(path.read_text())
|
||||||
path.unlink(missing_ok=True)
|
try:
|
||||||
(working_dir / STORE_DIR / narinfo['URL']).unlink(missing_ok=True)
|
path.unlink()
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
try:
|
||||||
|
(working_dir / STORE_DIR / narinfo['URL']).unlink()
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
|
||||||
if DELETE_OLD:
|
if DELETE_OLD:
|
||||||
logging.info(f' - {deleted} paths deleted')
|
logging.info(f' - {deleted} paths deleted')
|
||||||
|
Loading…
x
Reference in New Issue
Block a user