We are working on an ASP.NET Web Forms application using ASP.NET Membership for user related operations. When a user is created in the application, we add
him to two roles, a main and a sub role, as per the below code snippet.
Roles.AddUserToRole(userName, mainRoleName);
if (mainRoleName == "Test")
{
Roles.AddUserToRole(userName, subRoleName);
}
Rarely, we face an issue where the user gets added to the subRoleName but is not part of the mainRoleName. Is there any specific reason for this to happen
and anyone faced similar issues like the one mentioned?