From bec5eb85cc65dfc072f54145d91106e16827c96b Mon Sep 17 00:00:00 2001 From: gazebo Date: Mon, 11 Mar 2019 15:45:27 +0800 Subject: [PATCH] - fk --- business/auth2/auth2.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/business/auth2/auth2.go b/business/auth2/auth2.go index bd5ea8ac4..324e7324b 100644 --- a/business/auth2/auth2.go +++ b/business/auth2/auth2.go @@ -362,7 +362,7 @@ func GetTokenType(token string) (tokenType int) { func IsV2Token(token string) bool { tokenPartList := strings.Split(token, TokenTypeSep) - return tokenPartList[1] == TokenVer + return len(tokenPartList) > 1 && tokenPartList[1] == TokenVer } func GuessAuthTypeFromAuthID(authID string) (authType string) {