1
Vote

-Name parameter on Get-UserRole can cause problems because it searches both DisplayName and Name

description

foreach(UserRole role in _mg.Security.GetUserRoles())
        {
            if ( r.Match(role.Name).Success || r.Match(role.DisplayName).Success)
            {
                WriteObject(role);
            }
        }

comments