上传武馆切磋 优化
This commit is contained in:
parent
e2f3ff5626
commit
5d3a0e40c3
@ -31,12 +31,6 @@ func (this *apiComp) Qiecuo(session comm.IUserSession, req *pb.PracticeQiecuoReq
|
||||
keep bool
|
||||
)
|
||||
|
||||
//目标是否在线
|
||||
if !this.module.ModuleUser.IsOnline(req.Fid) {
|
||||
code = pb.ErrorCode_UserOffline
|
||||
return
|
||||
}
|
||||
|
||||
//切磋请求处理
|
||||
if result, err = this.module.modelQiecuo.queryQiecuo(session.GetUserId()); err != nil {
|
||||
code = pb.ErrorCode_DBError
|
||||
@ -69,6 +63,11 @@ func (this *apiComp) Qiecuo(session comm.IUserSession, req *pb.PracticeQiecuoReq
|
||||
}
|
||||
}
|
||||
}
|
||||
//目标是否在线
|
||||
if !this.module.ModuleUser.IsOnline(req.Fid) {
|
||||
code = pb.ErrorCode_UserOffline
|
||||
return
|
||||
}
|
||||
|
||||
if user = this.module.ModuleUser.GetUser(session.GetUserId()); user == nil {
|
||||
code = pb.ErrorCode_DBError
|
||||
|
Loading…
Reference in New Issue
Block a user