Skip to content

Commit 004fd61

Browse files
author
Hieu Lam - TMA
authored
fix-9018: Error when trying to export attendees (#9031)
1 parent ebd51f1 commit 004fd61

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

app/api/celery_tasks.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,7 @@ def celery_task(task_id):
3131
if type(info) is dict:
3232
# check if is error
3333
if '__error' in info:
34-
return info['result']
34+
return jsonify(state='FAILURE', result=info['result'])
3535
# return normal
36-
return jsonify(state='SUCCESS', result=info)
37-
if state == 'FAILURE':
38-
return jsonify(state=state)
36+
return jsonify(state=state, result=info)
3937
return jsonify(state=state)

0 commit comments

Comments
 (0)