#27819 好友黑名单BUG
This commit is contained in:
parent
509e1d6b60
commit
adced06a7a
@ -90,10 +90,13 @@ func (this *apiComp) Addblack(session comm.IUserSession, req *pb.FriendAddBlackR
|
|||||||
// 将目标从好友列表中移除
|
// 将目标从好友列表中移除
|
||||||
friendIds := utils.Deletex(self.FriendIds, req.FriendId)
|
friendIds := utils.Deletex(self.FriendIds, req.FriendId)
|
||||||
|
|
||||||
|
// 将好友从申请列表移除
|
||||||
|
applyIds := utils.Deletex(self.ApplyIds, req.FriendId)
|
||||||
//更新
|
//更新
|
||||||
err = this.module.modelFriend.Change(self.Uid, map[string]interface{}{
|
err = this.module.modelFriend.Change(self.Uid, map[string]interface{}{
|
||||||
"blackIds": self.BlackIds,
|
"blackIds": self.BlackIds,
|
||||||
"friendIds": friendIds,
|
"friendIds": friendIds,
|
||||||
|
"applyIds": applyIds,
|
||||||
})
|
})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
errdata = &pb.ErrorData{
|
errdata = &pb.ErrorData{
|
||||||
|
@ -110,6 +110,7 @@ func (this *apiComp) Agree(session comm.IUserSession, req *pb.FriendAgreeReq) (e
|
|||||||
}
|
}
|
||||||
if err = this.module.modelFriend.Change(target.Uid, map[string]interface{}{
|
if err = this.module.modelFriend.Change(target.Uid, map[string]interface{}{
|
||||||
"friendIds": target.FriendIds,
|
"friendIds": target.FriendIds,
|
||||||
|
"applyIds": target.ApplyIds,
|
||||||
}); err != nil {
|
}); err != nil {
|
||||||
errdata = &pb.ErrorData{
|
errdata = &pb.ErrorData{
|
||||||
Code: pb.ErrorCode_DBError,
|
Code: pb.ErrorCode_DBError,
|
||||||
|
Loading…
Reference in New Issue
Block a user