Skip to content

Commit

Permalink
fix: cell doesn't working
Browse files Browse the repository at this point in the history
  • Loading branch information
Yazawazi committed Feb 16, 2024
1 parent f1b4f69 commit 286d96e
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions backend/funix/decorator/call.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,8 @@ def output_to_web_function(**wrapped_function_kwargs):
}
)
)
ws.close()
return
else:
result = []
for temp_function_result in function(**arg):
Expand All @@ -285,16 +287,18 @@ def output_to_web_function(**wrapped_function_kwargs):
result.extend(function_result)
else:
result.append(function_result)
ws.send(dumps({"result": result}))
result = []
ws.close()
else:
temp_result = wrapped_function(**arg)
if isinstance(temp_result, list):
result.extend(temp_result)
else:
result.append(temp_result)
return [{"result": result}]
if need_websocket:
ws.send(dumps({"result": result}))
ws.close()
return
else:
return [{"result": result}]
elif len(upload_base64_files) > 0:
new_args = function_kwargs
for upload_base64_file_key in upload_base64_files.keys():
Expand Down

0 comments on commit 286d96e

Please sign in to comment.