From e68d228e92502b3d8289c596d8013c23546e039c Mon Sep 17 00:00:00 2001 From: Andy Zhang <37402126+AnzhiZhang@users.noreply.github.com> Date: Mon, 27 Jun 2022 00:35:33 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=F0=9F=94=A5=20remove=20downloading=20di?= =?UTF-8?q?r=20at=20startup?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/main.py b/main.py index 276fd33..4a97fbe 100644 --- a/main.py +++ b/main.py @@ -9,8 +9,9 @@ def main(): if not os.path.isdir(PATH.DATA_DIR): os.mkdir(PATH.DATA_DIR) - if not os.path.isdir(PATH.DOWNLOADING_DIR_PATH): - os.mkdir(PATH.DOWNLOADING_DIR_PATH) + if os.path.isdir(PATH.DOWNLOADING_DIR_PATH): + shutil.rmtree(PATH.DOWNLOADING_DIR_PATH) + os.mkdir(PATH.DOWNLOADING_DIR_PATH) factory = Factory() Main(factory).main()