super group add

This commit is contained in:
Gordon
2022-07-06 15:28:34 +08:00
parent 2b6f861f3b
commit c638072902
2 changed files with 13 additions and 4 deletions
+10 -1
View File
@@ -183,7 +183,16 @@ func groupNotification(contentType int32, m proto.Message, sendID, groupID, recv
n.SendID = sendID
if groupID != "" {
n.RecvID = groupID
n.SessionType = constant.GroupChatType
group, err := imdb.GetGroupInfoByGroupID(groupID)
if err != nil {
log.NewError(operationID, "GetGroupInfoByGroupID failed ", err.Error(), groupID)
}
switch group.GroupType {
case constant.NormalGroup:
n.SessionType = constant.GroupChatType
default:
n.SessionType = constant.SuperGroupChatType
}
} else {
n.RecvID = recvUserID
n.SessionType = constant.SingleChatType