refreshFix:Removing expiry check

This commit is contained in:
princemelvin 2021-04-29 20:28:05 +05:30
parent 42475c28f7
commit 2de1ad441a
1 changed files with 1 additions and 1 deletions

View File

@ -116,7 +116,7 @@ func (p *OIDCProvider) ValidateSession(ctx context.Context, s *sessions.SessionS
// RefreshSessionIfNeeded checks if the session has expired and uses the
// RefreshToken to fetch a new Access Token (and optional ID token) if required
func (p *OIDCProvider) RefreshSessionIfNeeded(ctx context.Context, s *sessions.SessionState) (bool, error) {
if s == nil || (s.ExpiresOn != nil && s.ExpiresOn.After(time.Now())) || s.RefreshToken == "" {
if s == nil || s.RefreshToken == "" {
return false, nil
}