fix: only show factors with state ready (#3081)

This commit is contained in:
Fabi
2022-01-21 09:27:57 +01:00
committed by GitHub
parent b363ddd707
commit 2592383a7c
4 changed files with 29 additions and 0 deletions

View File

@@ -22,6 +22,10 @@ func (s *Server) ListMyAuthFactors(ctx context.Context, _ *auth_pb.ListMyAuthFac
if err != nil {
return nil, err
}
err = query.AppendStateQuery(domain.MFAStateReady)
if err != nil {
return nil, err
}
authMethods, err := s.query.SearchUserAuthMethods(ctx, query)
if err != nil {
return nil, err