fix: last eight token

This commit is contained in:
Jason Song 2022-12-23 13:18:02 +08:00
parent 4782792604
commit 255d778737
No known key found for this signature in database
GPG Key ID: 8402EEEE4511A8B5

View File

@ -26,7 +26,7 @@ func generateSaltedToken() (string, string, string, string, error) {
}
token := hex.EncodeToString(buf)
hash := auth_model.HashToken(token, salt)
return token, salt, hash, token[:8], nil
return token, salt, hash, token[len(token)-8:], nil
}
/*