File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -56,7 +56,7 @@ func (c RegisteredClaims) Valid() error {
5656 // default value in Go, let's not fail the verification for them.
5757 if ! c .VerifyExpiresAt (now , false ) {
5858 delta := now .Sub (c .ExpiresAt .Time )
59- vErr .Inner = fmt .Errorf ("%s by %v " , delta , ErrTokenExpired )
59+ vErr .Inner = fmt .Errorf ("%s by %s " , ErrTokenExpired , delta )
6060 vErr .Errors |= ValidationErrorExpired
6161 }
6262
@@ -149,7 +149,7 @@ func (c StandardClaims) Valid() error {
149149 // default value in Go, let's not fail the verification for them.
150150 if ! c .VerifyExpiresAt (now , false ) {
151151 delta := time .Unix (now , 0 ).Sub (time .Unix (c .ExpiresAt , 0 ))
152- vErr .Inner = fmt .Errorf ("%s by %v " , delta , ErrTokenExpired )
152+ vErr .Inner = fmt .Errorf ("%s by %s " , ErrTokenExpired , delta )
153153 vErr .Errors |= ValidationErrorExpired
154154 }
155155
You can’t perform that action at this time.
0 commit comments