Get converastion id before retrieving relevant notes in non-socket code

This commit is contained in:
sabaimran 2024-06-17 14:26:06 +05:30
parent d2d9f4888e
commit ba0187798a

View file

@ -831,6 +831,7 @@ async def chat(
conversation = await ConversationAdapters.aget_conversation_by_user(
user, request.user.client_app, conversation_id, title
)
conversation_id = conversation.id if conversation else None
if not conversation:
return Response(
content=f"No conversation found with requested id, title", media_type="text/plain", status_code=400