forked from mirror/jwt
updated README with new argument order for WithClaims methods
This commit is contained in:
parent
5e270fa6cd
commit
b9283128ba
|
@ -93,7 +93,7 @@ On the other end of usage all of the `jwt.Parse` and friends got a `WithClaims`
|
||||||
|
|
||||||
New method usage:
|
New method usage:
|
||||||
```go
|
```go
|
||||||
token, err := jwt.ParseWithClaims(token, keyFunc, &jwt.StandardClaims{})
|
token, err := jwt.ParseWithClaims(token, &jwt.StandardClaims{}, keyFunc)
|
||||||
claims := token.Claims.(jwt.StandardClaims)
|
claims := token.Claims.(jwt.StandardClaims)
|
||||||
fmt.Println(claims.IssuedAt)
|
fmt.Println(claims.IssuedAt)
|
||||||
```
|
```
|
||||||
|
|
Loading…
Reference in New Issue