rollback code

This commit is contained in:
咕谷酱
2025-08-22 15:07:50 +08:00
parent b1f0cbfed1
commit e293d7541b
12 changed files with 74 additions and 1710 deletions

View File

@@ -358,7 +358,9 @@ class RedisMessageSystem:
# 确保消息按ID正序排序时间顺序
messages.sort(key=lambda x: x.get("message_id", 0))
return messages
# 如果是获取最新消息since=0需要保持倒序最新的在前面
if since == 0:
messages.reverse()
return messages