Base solution for your next web application
Open Closed

Login with only username and Password #2264


User avatar
0
shyamjith created

Hi,

I am using " _userManager.LoginAsync(usernameOrEmailAddress, password, tenancyName);" Method to login the application, which will accept both username and email address. but my requirement is to authenticate user only with Username and password not with Email and password, How do I do that?


1 Answer(s)
  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    You can check entered username before callling _userManager.LoginAsync in serverside and don't call _userManager.LoginAsync if it is a valid email address.

    You can even do it on the client side before calling the server.