Bug when directory is empty with new file upload (server side)

This commit is contained in:
Simon 2018-07-17 18:28:50 -04:00
parent 8ef1d36c9d
commit df5b01dc83

2
app.py
View File

@ -563,6 +563,8 @@ def api_complete_task():
if task: if task:
filename = "./tmp/" + str(task_result.website_id) + ".json" filename = "./tmp/" + str(task_result.website_id) + ".json"
if not os.path.exists(filename):
filename = None
taskManager.complete_task(filename, task, task_result, name) taskManager.complete_task(filename, task, task_result, name)
if filename and os.path.exists(filename): if filename and os.path.exists(filename):