mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-12-19 12:47:06 +08:00
fix bug: msg notification self 2 self push twice
This commit is contained in:
parent
3584d2f620
commit
95fd4ba2c3
@ -65,7 +65,13 @@ func (c *ConsumerHandler) handleMs2PsChat(ctx context.Context, msg []byte) {
|
||||
case constant.SuperGroupChatType:
|
||||
err = c.pusher.Push2SuperGroup(ctx, pbData.MsgData.GroupID, pbData.MsgData)
|
||||
default:
|
||||
err = c.pusher.Push2User(ctx, []string{pbData.MsgData.SendID, pbData.MsgData.RecvID}, pbData.MsgData)
|
||||
var pushUserIDs []string
|
||||
if pbData.MsgData.SendID != pbData.MsgData.RecvID {
|
||||
pushUserIDs = []string{pbData.MsgData.SendID, pbData.MsgData.RecvID}
|
||||
} else {
|
||||
pushUserIDs = []string{pbData.MsgData.SendID}
|
||||
}
|
||||
err = c.pusher.Push2User(ctx, pushUserIDs, pbData.MsgData)
|
||||
}
|
||||
if err != nil {
|
||||
if err == errNoOfflinePusher {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user