feat 修复会话列表

This commit is contained in:
chen zida
2023-12-05 17:30:38 +08:00
parent 3af5cc5f6e
commit 8aa642ecb4

View File

@@ -221,9 +221,9 @@ public class MessageSyncService {
.collect(Collectors.toMap(ImMessageHistoryEntity::getToId, x -> x));
// 合并map到toId
fromIdMap.forEach((key,value) -> {
toIdMap.merge(key,value,(x,y) -> {
if (value.getMessageKey() > y.getMessageKey()) return value;
return y;
toIdMap.merge(key,value,(v1,v2) -> {
if (v1.getMessageKey() > v2.getMessageKey()) return v1;
return v2;
});
});