u
This commit is contained in:
1 parent
3af982d669
commit
6a24be0864
28 files changed
+572
-458
No files matched your search
@@ -5,8 +5,9 @@ import (
|
||||
"cn/oneao/base-go/utils/pathx"
|
||||
"cn/oneao/base-go/utils/response"
|
||||
"context"
|
||||
"github.com/cloudwego/hertz/pkg/app"
|
||||
"strconv"
|
||||
|
||||
"github.com/cloudwego/hertz/pkg/app"
|
||||
)
|
||||
|
||||
// 私有 key,防止冲突
|
||||
@@ -36,7 +37,6 @@ func Auth() app.HandlerFunc {
|
||||
|
||||
token := string(c.GetHeader("token"))
|
||||
spaceId := string(c.GetHeader("x-space-id"))
|
||||
|
||||
if token == "" {
|
||||
response.Fail(c).Code(response.HttpCode.Unauthorized).Send()
|
||||
c.Abort()
|
||||
|
||||
Reference in new issue
Block a user