diff --git a/lib/robot.go b/lib/robot.go index 047976e..9d4047c 100644 --- a/lib/robot.go +++ b/lib/robot.go @@ -127,8 +127,14 @@ func (r *Robot) SendMsg(mainType, subType string, req proto.Message, rsp proto.M if !ProtoUnmarshal(msg, rsp) { break } - return pb.ErrorCode_Success + } else if msg.MainType == "notify" && msg.SubType == "errornotify" { + rsp := &pb.NotifyErrorNotifyPush{} + if !ProtoUnmarshal(msg, rsp) { + break + } + logrus.Info(rsp.Code) + return rsp.Code } } } @@ -224,7 +230,7 @@ func (m *Robot) syncCall() { //这里执行会花很长时间 if err := scene.Run(m); err != nil { logrus.WithField("err", err).Error("执行业务时发生错误") - break + continue } elapsedTime := time.Since(start)