From 272a3f347d97c48a97dcc68e689c48e5aa955b77 Mon Sep 17 00:00:00 2001 From: Kevin Wan Date: Sun, 16 Jan 2022 10:34:44 +0800 Subject: [PATCH] chore: remove jwt deprecated (#1452) --- rest/token/tokenparser.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/rest/token/tokenparser.go b/rest/token/tokenparser.go index a0cd9169..2e1ef68c 100644 --- a/rest/token/tokenparser.go +++ b/rest/token/tokenparser.go @@ -120,7 +120,5 @@ func WithResetDuration(duration time.Duration) ParseOption { } func newParser() *jwt.Parser { - return &jwt.Parser{ - UseJSONNumber: true, - } + return jwt.NewParser(jwt.WithJSONNumber()) }