chore(auth): #331 add first session test
Some checks failed
Build Docker Image / Build-Docker-Image (push) Failing after 39s
Some checks failed
Build Docker Image / Build-Docker-Image (push) Failing after 39s
This commit is contained in:
@@ -99,6 +99,7 @@ func (service AuthImpl) SignInSession(sessionId string) (*types.Session, *types.
|
||||
return nil, nil, types.ErrInternal
|
||||
}
|
||||
if session.ExpiresAt.Before(service.clock.Now()) {
|
||||
_ = service.db.DeleteSession(sessionId)
|
||||
return nil, nil, nil
|
||||
}
|
||||
|
||||
@@ -130,7 +131,6 @@ func (service AuthImpl) createSession(userId uuid.UUID) (*types.Session, error)
|
||||
}
|
||||
|
||||
err = service.db.DeleteOldSessions(userId)
|
||||
|
||||
if err != nil {
|
||||
return nil, types.ErrInternal
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user