You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Dec 20, 2018. It is now read-only.
When I read the code for FindByNameAsync, the UserManager will first normalize the user name then pass to UserStore to find the user by the normalized user name.
However, when adding roles to a user, the UserManager only pass the rolename without any normalizations. This pattern is not consistent with the previous case.
And the related issue is that the UserStore in entityframework search for the roles by only using just a upper case comparison.
var roleEntity = await Roles.SingleOrDefaultAsync(r => r.Name.ToUpper() == roleName.ToUpper(), cancellationToken);