Hello team,
Whenever I add an associate to my system I'm assigning a role="Accountant" to that associate but by default a role "system user" gets added to it as well. I don't want that 'system user' role or want to remove 'system user' role for each associate I add .I only want 'Accountant' as the role of the associate.How can I achieve this?

This is my code to add Role to the associate:
SecurityRole role;
SecurityUserRole userRole;
SystemUserEntity systemuser;
select role where role.Name==securityrole; //role=="Accountant"
select * from userRole
where userRole.SecurityRole == role.RecId && userRole.User == systemuser.UserID;
userRole.User = systemuser.UserID;
userRole.SecurityRole = role.RecId;
userRole.AssignmentMode = RoleAssignmentMode::Manual;
userRole.AssignmentStatus = RoleAssignmentStatus::Enabled;
SecuritySegregationOfDuties::assignUserToRole(userRole, null);
info(strFmt("Role %1 added to the user %2 successfully.", role.Name, systemuser.UserId));