From 383ae8e47e7927f0147809a83684b91c3aa96f07 Mon Sep 17 00:00:00 2001 From: Gordon <46924906+FGadvancer@users.noreply.github.com> Date: Mon, 7 Aug 2023 19:51:06 +0800 Subject: [PATCH] refactor: log change Signed-off-by: Gordon <46924906+FGadvancer@users.noreply.github.com> --- internal/msggateway/message_handler.go | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/internal/msggateway/message_handler.go b/internal/msggateway/message_handler.go index 8e3512238..bdf14a1a8 100644 --- a/internal/msggateway/message_handler.go +++ b/internal/msggateway/message_handler.go @@ -39,7 +39,13 @@ type Req struct { } func (r *Req) String() string { - return utils.StructToJsonString(r) + var tReq Req + tReq.ReqIdentifier = r.ReqIdentifier + tReq.Token = r.Token + tReq.SendID = r.SendID + tReq.OperationID = r.OperationID + tReq.MsgIncr = r.MsgIncr + return utils.StructToJsonString(tReq) } type Resp struct { @@ -52,6 +58,12 @@ type Resp struct { } func (r *Resp) String() string { + var tResp Resp + tResp.ReqIdentifier = r.ReqIdentifier + tResp.MsgIncr = r.MsgIncr + tResp.OperationID = r.OperationID + tResp.ErrCode = r.ErrCode + tResp.ErrMsg = r.ErrMsg return utils.StructToJsonString(r) }