Example #1
0
 public override bool DeleteRole(string roleName, bool throwOnPopulatedRole)
 {
     if (throwOnPopulatedRole && (0 < this.GetUsersInRole(roleName).Length))
     {
         throw NhibernateMembershipProviderExceptionUtil.NewProviderException(this, "role is not empty.");
     }
     try
     {
         return(SystemRoleWrapper.DeleteRole(roleName, throwOnPopulatedRole));
     }
     catch (Exception exception)
     {
         throw NhibernateMembershipProviderExceptionUtil.NewProviderException(this, NHibernateProviderSR.Role_UnableToDelete, exception);
     }
 }