Skip to content

Commit ab972fd

Browse files
committed
feat: support command in mcp
1 parent 2cf44ac commit ab972fd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

backend/apps/chat/api/chat.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ async def question_answer_inner(session: SessionDep, current_user: CurrentUser,
200200
stmt = select(ChatRecord.id, ChatRecord.chat_id, ChatRecord.analysis_record_id,
201201
ChatRecord.predict_record_id, ChatRecord.regenerate_record_id,
202202
ChatRecord.first_chat).where(
203-
and_(ChatRecord.id == record_id))
203+
and_(ChatRecord.id == record_id)).order_by(ChatRecord.create_time.desc())
204204
_record = session.execute(stmt).fetchone()
205205
if not _record:
206206
raise Exception(f'Record id: {record_id} does not exist')

0 commit comments

Comments
 (0)