From a929e523247e53ff58dd7e9f08f3989eb33cd00e Mon Sep 17 00:00:00 2001 From: Sinh Date: Thu, 14 Sep 2023 15:23:50 +0700 Subject: [PATCH] fix jtexpress digest --- partnerapi/jtexpress/jtexpress.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/partnerapi/jtexpress/jtexpress.go b/partnerapi/jtexpress/jtexpress.go index cc32ccf..4ff00f2 100644 --- a/partnerapi/jtexpress/jtexpress.go +++ b/partnerapi/jtexpress/jtexpress.go @@ -7,6 +7,7 @@ import ( "github.com/go-resty/resty/v2" + "git.selly.red/Selly-Modules/3pl/util/base64" "git.selly.red/Selly-Modules/3pl/util/pjson" ) @@ -115,5 +116,5 @@ func (c *Client) getDigest(data string) string { h := md5.New() io.WriteString(h, s) - return fmt.Sprintf("%x", h.Sum(nil)) + return base64.Encode([]byte(fmt.Sprintf("%x", h.Sum(nil)))) }