Эх сурвалжийг харах

会话列表返回了密码

xuqm 1 жил өмнө
parent
commit
abc1a3c202

+ 4 - 2
src/main/java/cn/org/bjca/trust/java/imserver/im/ImManager.java

@@ -90,12 +90,12 @@ public class ImManager {
                                 SZYXMessage message2 = message1.copy();
                                 message2.setUserName(groupEntity.getUserId());
                                 saveConversation(message2);
-                                sendPacketMessage(szyxMessage.getPacketType(), message2);
+                                sendPacketMessage(PacketType.SEND, message2);
                             }
                         } else {
                             message1.setUserName(message1.getToClientId());
                             saveConversation(message1);
-                            sendPacketMessage(szyxMessage.getPacketType(), message1);
+                            sendPacketMessage(PacketType.SEND, message1);
                         }
                         // TODO: 这里应该有计时器,判断转发消息是否送达,如果没送达则ack返回失败状态
                         sendAckMsg(szyxMessage);
@@ -144,6 +144,8 @@ public class ImManager {
             }
 
             conversationRepository.save(conversation);
+            conversation.getSelf().setPassword("");
+            conversation.getUserInfo().setPassword("");
             sendPacketMessage(PacketType.CONVERSATION, conversation);
         } catch (Exception e) {
             System.out.println("--------------" + e.getMessage());