Skip to content

Commit

Permalink
merge fix
Browse files Browse the repository at this point in the history
  • Loading branch information
tmm360 committed Sep 21, 2022
2 parents 752a300 + a11e1c2 commit bff2374
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 10 deletions.
1 change: 0 additions & 1 deletion src/EthernaSSO.Domain/Models/UserBase.cs
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,6 @@ public virtual IEnumerable<string> EtherPreviousAddresses

public virtual UserBase? InvitedBy { get; protected set; }
public virtual bool InvitedByAdmin { get; protected set; }
public virtual bool IsInvited => InvitedByAdmin || InvitedBy is not null;
[PersonalData]
public virtual DateTime LastLoginDateTime { get; protected set; }
//public virtual bool LockoutEnabled => SharedInfo.LockoutEnabled;
Expand Down
9 changes: 0 additions & 9 deletions src/EthernaSSO/Configs/Identity/CustomUserValidator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -74,15 +74,6 @@ public virtual async Task<IdentityResult> ValidateAsync(UserManager<UserBase> ma
if (user is UserWeb2 userWeb2)
ValidateWeb2Logins(userWeb2, errors);

// Validate invitation.
if (user.Id is null && //is registering
applicationSettings.RequireInvitation && !user.IsInvited)
errors.Add(new IdentityError
{
Code = "RequiredInvitation",
Description = "An invitation code is required"
});

return errors.Count > 0 ? IdentityResult.Failed(errors.ToArray()) : IdentityResult.Success;
}

Expand Down

0 comments on commit bff2374

Please sign in to comment.