mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-12-08 21:47:17 +08:00
fix:fix the error parse
This commit is contained in:
parent
b7b049e4b1
commit
09f0fbda39
@ -69,6 +69,7 @@ func CallbackBeforeCreateGroup(ctx context.Context, req *group.CreateGroupReq) (
|
|||||||
if err == errs.ErrCallbackContinue {
|
if err == errs.ErrCallbackContinue {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
utils.NotNilReplace(&req.GroupInfo.GroupID, resp.GroupID)
|
utils.NotNilReplace(&req.GroupInfo.GroupID, resp.GroupID)
|
||||||
|
|||||||
@ -14,9 +14,7 @@
|
|||||||
|
|
||||||
package callbackstruct
|
package callbackstruct
|
||||||
|
|
||||||
import (
|
import "github.com/OpenIMSDK/tools/errs"
|
||||||
"github.com/OpenIMSDK/tools/errs"
|
|
||||||
)
|
|
||||||
|
|
||||||
type CommonCallbackReq struct {
|
type CommonCallbackReq struct {
|
||||||
SendID string `json:"sendID"`
|
SendID string `json:"sendID"`
|
||||||
@ -59,7 +57,7 @@ type CommonCallbackResp struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (c CommonCallbackResp) Parse() error {
|
func (c CommonCallbackResp) Parse() error {
|
||||||
if c.ActionCode != errs.NoError || c.ErrCode != errs.NoError {
|
if c.ActionCode != errs.NoError || c.NextCode == 1 {
|
||||||
return errs.NewCodeError(int(c.ErrCode), c.ErrMsg).WithDetail(c.ErrDlt)
|
return errs.NewCodeError(int(c.ErrCode), c.ErrMsg).WithDetail(c.ErrDlt)
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user