From c4f327562f630967d16c07ddf514bbc237092129 Mon Sep 17 00:00:00 2001 From: shanshanzhong Date: Tue, 6 Jan 2026 22:55:10 -0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E8=AE=B0=E5=BD=95=20Telegram=20?= =?UTF-8?q?=E9=85=8D=E7=BD=AE=E5=90=AF=E7=94=A8=E7=8A=B6=E6=80=81=E5=B9=B6?= =?UTF-8?q?=E5=88=9D=E5=A7=8B=E5=8C=96=E8=AE=BE=E5=A4=87=E4=B8=AD=E9=97=B4?= =?UTF-8?q?=E4=BB=B6=E5=93=8D=E5=BA=94=E5=86=99=E5=85=A5=E5=99=A8=E5=AD=97?= =?UTF-8?q?=E6=AE=B5=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- initialize/telegram.go | 1 + internal/middleware/deviceMiddleware.go | 2 ++ 2 files changed, 3 insertions(+) diff --git a/initialize/telegram.go b/initialize/telegram.go index fb5856a..6a846f6 100644 --- a/initialize/telegram.go +++ b/initialize/telegram.go @@ -14,6 +14,7 @@ import ( ) func Telegram(svc *svc.ServiceContext) { + logger.Infof("Telegram Config Enable: %v", svc.Config.Telegram.Enable) if !svc.Config.Telegram.Enable { return } diff --git a/internal/middleware/deviceMiddleware.go b/internal/middleware/deviceMiddleware.go index 19e2b3c..a56ef16 100644 --- a/internal/middleware/deviceMiddleware.go +++ b/internal/middleware/deviceMiddleware.go @@ -74,6 +74,8 @@ func NewResponseWriter(c *gin.Context, srvCtx *svc.ServiceContext) (rw *Response c: c, body: new(bytes.Buffer), ResponseWriter: c.Writer, + size: noWritten, + status: defaultStatus, } rw.encryptionKey = srvCtx.Config.Device.SecuritySecret rw.encryptionMethod = "AES"