Merge branch 'main' of https://github.com/xerrors/Yuxi-Know
This commit is contained in:
commit
751bd3c791
@ -164,14 +164,14 @@ async def get_conversation_detail(
|
|||||||
"""Get conversation detail (Admin only)"""
|
"""Get conversation detail (Admin only)"""
|
||||||
try:
|
try:
|
||||||
conv_manager = ConversationManager(db)
|
conv_manager = ConversationManager(db)
|
||||||
conversation = conv_manager.get_conversation_by_thread_id(thread_id)
|
conversation = await conv_manager.get_conversation_by_thread_id(thread_id)
|
||||||
|
|
||||||
if not conversation:
|
if not conversation:
|
||||||
raise HTTPException(status_code=404, detail="Conversation not found")
|
raise HTTPException(status_code=404, detail="Conversation not found")
|
||||||
|
|
||||||
# Get messages and stats
|
# Get messages and stats
|
||||||
messages = conv_manager.get_messages(conversation.id)
|
messages = await conv_manager.get_messages(conversation.id)
|
||||||
stats = conv_manager.get_stats(conversation.id)
|
stats = await conv_manager.get_stats(conversation.id)
|
||||||
|
|
||||||
# Format messages
|
# Format messages
|
||||||
message_list = []
|
message_list = []
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user