File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
python/samples/demos/chatkit-integration Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -589,7 +589,7 @@ async def upload_file(attachment_id: str, file: UploadFile = File(...)):
589589
590590 except Exception as e :
591591 logger .error (f"Error uploading file for attachment { attachment_id } : { e } " , exc_info = True )
592- return JSONResponse (status_code = 500 , content = {"error" : f "Failed to upload file: { str ( e ) } " })
592+ return JSONResponse (status_code = 500 , content = {"error" : "Failed to upload file. " })
593593
594594
595595@app .get ("/preview/{attachment_id}" )
@@ -620,7 +620,7 @@ async def preview_image(attachment_id: str):
620620
621621 except Exception as e :
622622 logger .error (f"Error serving preview for attachment { attachment_id } : { e } " , exc_info = True )
623- return JSONResponse (status_code = 500 , content = {"error" : str ( e ) })
623+ return JSONResponse (status_code = 500 , content = {"error" : "Error serving preview for attachment." })
624624
625625
626626if __name__ == "__main__" :
You can’t perform that action at this time.
0 commit comments