mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-11 19:07:30 +00:00
refactor: cleanup unused code (#7130)
* refactor: drop unused code * refactor: drop unused code
This commit is contained in:
@@ -7,7 +7,6 @@ import (
|
||||
|
||||
"github.com/zitadel/zitadel/internal/domain"
|
||||
"github.com/zitadel/zitadel/internal/eventstore/v1/models"
|
||||
iam_model "github.com/zitadel/zitadel/internal/iam/model"
|
||||
"github.com/zitadel/zitadel/internal/zerrors"
|
||||
)
|
||||
|
||||
@@ -231,20 +230,6 @@ func (u *UserView) IsPasswordlessReady() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
func (u *UserView) HasRequiredOrgMFALevel(policy *iam_model.LoginPolicyView) bool {
|
||||
if !policy.ForceMFA {
|
||||
return true
|
||||
}
|
||||
switch u.MFAMaxSetUp {
|
||||
case domain.MFALevelSecondFactor:
|
||||
return policy.HasSecondFactors()
|
||||
case domain.MFALevelMultiFactor:
|
||||
return policy.HasMultiFactors()
|
||||
default:
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
func (u *UserView) GetProfile() (*Profile, error) {
|
||||
if u.HumanView == nil {
|
||||
return nil, zerrors.ThrowPreconditionFailed(nil, "MODEL-WLTce", "Errors.User.NotHuman")
|
||||
|
Reference in New Issue
Block a user