From 0e37888c30392e4ca2be23b0e614a2c5459b2f52 Mon Sep 17 00:00:00 2001 From: Twilight Date: Tue, 14 May 2024 15:13:45 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E8=BF=9B=20gin=20release=20mode?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/main.go b/main.go index f0239ff..6c39640 100644 --- a/main.go +++ b/main.go @@ -46,6 +46,8 @@ func main() { } func InitGin() { + gin.SetMode(gin.ReleaseMode) + Router = gin.Default() } @@ -82,7 +84,7 @@ func Controller() { } func ValidatePassword(pass string) bool { - return pass == "Bearer "+config.Auth.Pass + return pass == config.Auth.Pass } func Process(logStruct LogStruct) error {