修复武馆驱逐 消息推送
This commit is contained in:
parent
38a6311b11
commit
313a705b94
@ -177,29 +177,20 @@ func (this *apiComp) Expulsion(session comm.IUserSession, req *pb.PracticeExpuls
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
defer func() {
|
|
||||||
if ok { //在线直接推送消息
|
|
||||||
this.module.PutUserSession(_session)
|
|
||||||
}
|
|
||||||
}()
|
|
||||||
_session, ok = this.module.GetUserSession(pillar.Uid)
|
_session, ok = this.module.GetUserSession(pillar.Uid)
|
||||||
// if _session, ok = this.module.GetUserSession(pillar.Uid); ok {
|
|
||||||
// if _, code = this.module.ModuleHero.AddHeroExp(_session, pillar.Hero, exp); code != pb.ErrorCode_Success {
|
|
||||||
// return
|
|
||||||
// }
|
|
||||||
// if code = this.module.DispenseRes(_session, append(ants1, ants2...), true); code != pb.ErrorCode_Success {
|
|
||||||
// return
|
|
||||||
// }
|
|
||||||
// if code = this.module.ModuleHero.KungFuHero(_session, pillar.Hero, false, ""); code != pb.ErrorCode_Success {
|
|
||||||
// return
|
|
||||||
// }
|
|
||||||
// } else {
|
|
||||||
if _, code = this.module.ModuleHero.AddHeroExp(_session, pillar.Hero, exp); code != pb.ErrorCode_Success {
|
if _, code = this.module.ModuleHero.AddHeroExp(_session, pillar.Hero, exp); code != pb.ErrorCode_Success {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if code = this.module.ModuleHero.KungFuHero(_session, pillar.Hero, false, ""); code != pb.ErrorCode_Success {
|
if code = this.module.ModuleHero.KungFuHero(_session, pillar.Hero, false, ""); code != pb.ErrorCode_Success {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
if ok { //在线直接推送消息
|
||||||
|
if err = _session.Push(); err != nil {
|
||||||
|
this.module.Errorln(err)
|
||||||
|
}
|
||||||
|
this.module.PutUserSession(_session)
|
||||||
|
}
|
||||||
|
|
||||||
res := make([]*pb.UserAssets, 0)
|
res := make([]*pb.UserAssets, 0)
|
||||||
for _, v := range ants1 {
|
for _, v := range ants1 {
|
||||||
res = append(res, &pb.UserAssets{
|
res = append(res, &pb.UserAssets{
|
||||||
|
Loading…
Reference in New Issue
Block a user