From 2bd2068c999cda5bda8c0787ed0dcaac6cb7afdb Mon Sep 17 00:00:00 2001 From: zhangzengfei <zhangzengfei@iotlink.com> Date: 星期四, 31 十月 2019 13:27:46 +0800 Subject: [PATCH] feat: add system reboot api --- middlewares/auth/jwt.go | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/middlewares/auth/jwt.go b/middlewares/auth/jwt.go index 0187b2f..aadecf4 100644 --- a/middlewares/auth/jwt.go +++ b/middlewares/auth/jwt.go @@ -55,7 +55,7 @@ if jwtUser, exist := c.Get("User"); !exist { tokenStr := strings.Replace(c.Request.Header.Get("Authorization"), "Bearer ", "", -1) if tokenStr == "" { - return map[interface{}]interface{}{} + return nil } var err error jwtToken, err = jwtLib.Parse(tokenStr, func(token *jwtLib.Token) (interface{}, error) { -- Gitblit v1.8.0