From 5e4a0b18bb3adc783eebd7c1438394760f87b277 Mon Sep 17 00:00:00 2001 From: hupeng Date: Sun, 7 Mar 2021 10:56:14 +0800 Subject: [PATCH] update main.go --- main.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/main.go b/main.go index 0f71aeb..114c8b3 100644 --- a/main.go +++ b/main.go @@ -72,12 +72,12 @@ func main() { }else { method := strings.ToLower(ctx.Input.Method()) //部署线上开启 - prohibit := "post,put,delete" - if url != "/admin/auth/logout" && strings.Contains(prohibit,method) { - ctx.Output.JSON(controllers.ErrMsg("演示环境禁止操作",40006), - true,true) - return - } + //prohibit := "post,put,delete" + //if url != "/admin/auth/logout" && strings.Contains(prohibit,method) { + // ctx.Output.JSON(controllers.ErrMsg("演示环境禁止操作",40006), + // true,true) + // return + //} mytoken := ctx.Input.Header("Authorization") if len(mytoken) < bearerLength { ctx.Output.Status = 401