mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-04-06 04:15:46 +08:00
group mute
This commit is contained in:
parent
296def6596
commit
9069170b3d
@ -91,13 +91,13 @@ func (m *msgServer) messageVerification(ctx context.Context, data *msg.SendMsgRe
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if groupMemberInfo.RoleLevel > constant.GroupOrdinaryUsers {
|
||||
if groupMemberInfo.RoleLevel == constant.GroupOwner {
|
||||
return nil
|
||||
} else {
|
||||
if groupMemberInfo.MuteEndTime >= time.Now().Unix() {
|
||||
return errs.ErrMutedInGroup.Wrap()
|
||||
}
|
||||
if groupInfo.Status == constant.GroupStatusMuted {
|
||||
if groupInfo.Status == constant.GroupStatusMuted && groupMemberInfo.RoleLevel != constant.GroupAdmin {
|
||||
return errs.ErrMutedGroup.Wrap()
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user