From 3429f61ebc68e6aadfcad15181d027879e0494a6 Mon Sep 17 00:00:00 2001 From: laodaming <11058467+laudamine@user.noreply.gitee.com> Date: Tue, 7 Nov 2023 14:39:34 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E9=A3=9E=E4=B9=A6webhook?= =?UTF-8?q?=E7=9B=91=E5=90=AC=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/feishu-sync/internal/logic/webhooklogic.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/feishu-sync/internal/logic/webhooklogic.go b/server/feishu-sync/internal/logic/webhooklogic.go index d513e44c..5bbb8b59 100644 --- a/server/feishu-sync/internal/logic/webhooklogic.go +++ b/server/feishu-sync/internal/logic/webhooklogic.go @@ -6,7 +6,7 @@ import ( "fusenapi/server/feishu-sync/internal/svc" "fusenapi/utils/feishu" "github.com/zeromicro/go-zero/core/logx" - "io/ioutil" + "io" "net/http" ) @@ -45,7 +45,7 @@ type BaseWebhookMsgHeaderType struct { } func (l *WebhookLogic) Webhook(w http.ResponseWriter, r *http.Request) { - bodyBytes, err := ioutil.ReadAll(r.Body) + bodyBytes, err := io.ReadAll(r.Body) if err != nil { logx.Error("读取请求body失败", err) return