Skip to content

Commit 57a65aa

Browse files
committed
modify the function
1 parent 2eca64d commit 57a65aa

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

server/server.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -511,12 +511,13 @@ func (s *Server) HandleTokenRequestWithDuration(w http.ResponseWriter, r *http.R
511511
return
512512
}
513513

514+
tgr.AccessTokenExp = duration
515+
514516
ti, verr := s.GetAccessToken(gt, tgr)
515517
if verr != nil {
516518
err = s.tokenError(w, verr)
517519
return
518520
}
519-
ti.SetAccessExpiresIn(duration)
520521

521522
err = s.token(w, s.GetTokenData(ti), nil)
522523
return

0 commit comments

Comments
 (0)