mirror of https://github.com/golang-jwt/jwt.git
Merge pull request #190 from jamesrwhite/patch-1
Clarify hmacSampleSecret type
This commit is contained in:
commit
a601269ab7
|
@ -51,6 +51,8 @@ func ExampleParse_hmac() {
|
|||
if _, ok := token.Method.(*jwt.SigningMethodHMAC); !ok {
|
||||
return nil, fmt.Errorf("Unexpected signing method: %v", token.Header["alg"])
|
||||
}
|
||||
|
||||
// hmacSampleSecret is a []byte containing your secret, e.g. []byte("my_secret_key")
|
||||
return hmacSampleSecret, nil
|
||||
})
|
||||
|
||||
|
|
Loading…
Reference in New Issue