public TwoFactorAuthPolicyCommandHandler(ITwoFactorAuthenticationPolicy policy) { if (policy == null) { throw new ArgumentNullException("policy"); } this.policy = policy; }
public static void ConfigureTwoFactorAuthenticationPolicy <TAccount>(this UserAccountService <TAccount> svc, ITwoFactorAuthenticationPolicy policy) where TAccount : UserAccount { if (svc == null) { throw new ArgumentNullException("account"); } svc.AddCommandHandler(new TwoFactorAuthPolicyCommandHandler(policy)); }
public static void ConfigureTwoFactorAuthenticationPolicy <TAccount>(this UserAccountService <TAccount> svc, ITwoFactorAuthenticationPolicy policy) where TAccount : UserAccount { svc.AddCommandHandler(new TwoFactorAuthPolicyCommandHandler(policy)); }