update log

This commit is contained in:
wh_zcy 2023-02-10 17:40:37 +08:00
parent 20c964dd5f
commit 618a3fae6b
2 changed files with 6 additions and 3 deletions

View File

@ -28,8 +28,6 @@ func (this *apiComp) Accept(session comm.IUserSession, req *pb.FriendAcceptReq)
now := configure.Now().Unix() now := configure.Now().Unix()
if now-qr.Timestamp > 10 { //大于10s 切磋超时 if now-qr.Timestamp > 10 { //大于10s 切磋超时
code = pb.ErrorCode_FriendQiecuoTimeout code = pb.ErrorCode_FriendQiecuoTimeout
//清除切磋记录
// this.moduleFriend.ModelFriendQiecuo.Del(req.Uid)
return return
} }
} else { } else {

View File

@ -180,7 +180,12 @@ func (this *Friend) UseAssistHero(uid, friendId string) (*pb.DBHero, error) {
func (this *Friend) QiecuoFinishNotify(redUid, matchId string) error { func (this *Friend) QiecuoFinishNotify(redUid, matchId string) error {
qr := this.ModelFriendQiecuo.getQiecuo(redUid) qr := this.ModelFriendQiecuo.getQiecuo(redUid)
if qr != nil && qr.MatchId == matchId { if qr != nil && qr.MatchId == matchId {
this.ModelFriendQiecuo.Del(redUid) log.Debug("清理切磋记录",
log.Field{Key: "redUid", Value: redUid},
log.Field{Key: "matchId", Value: matchId})
if err := this.ModelFriendQiecuo.Del(redUid); err != nil {
log.Error("删除", log.Field{Key: "redUid", Value: redUid})
}
} }
return nil return nil
} }