fix: fix the bug that if fail or success folder only has empty folders, it will also remove the fail or success folder.
This commit is contained in:
@@ -59,7 +59,7 @@ def rm_empty_folder(path):
|
||||
try:
|
||||
files = os.listdir(path) # 获取路径下的子文件(夹)列表
|
||||
for file in files:
|
||||
os.removedirs(path + '/' + file) # 删除这个空文件夹
|
||||
os.rmdir(path + '/' + file) # 删除这个空文件夹
|
||||
print('[+]Deleting empty folder', path + '/' + file)
|
||||
except:
|
||||
a = ''
|
||||
|
||||
Reference in New Issue
Block a user