Description
Get-TssGroupUser has both -Id (GroupId) and -UserId as mandatory parameters. The function name implies it retrieves the users belonging to a group, so -UserId should be optional (to allow retrieving all users) or the function should be renamed to make clear it only checks a specific user'''s membership.
Error
Cannot process command because of one or more missing mandatory parameters: UserId.
Repro
$session = New-TssSession -SecretServer https://labss01.jaggerlab.local/ -Credential $cred
$group = Search-TssGroup -TssSession $session | Select-Object -First 1
Get-TssGroupUser -TssSession $session -Id $group.Id
# ^ Fails: UserId is mandatory
Expected
Should return all users belonging to the specified group (like Get-TssGroupMember).
Environment
- Module version: 0.62.0 (dev branch)
- Secret Server version: 12.0.000022
- PowerShell: 7.x
Notes
Get-TssGroupMember works correctly with just a GroupId. If Get-TssGroupUser is intended only for membership checks on a specific user, consider renaming it to Test-TssGroupUser or Get-TssGroupMembership and documenting the distinction clearly.
Description
Get-TssGroupUserhas both-Id(GroupId) and-UserIdas mandatory parameters. The function name implies it retrieves the users belonging to a group, so-UserIdshould be optional (to allow retrieving all users) or the function should be renamed to make clear it only checks a specific user'''s membership.Error
Repro
Expected
Should return all users belonging to the specified group (like
Get-TssGroupMember).Environment
Notes
Get-TssGroupMemberworks correctly with just a GroupId. IfGet-TssGroupUseris intended only for membership checks on a specific user, consider renaming it toTest-TssGroupUserorGet-TssGroupMembershipand documenting the distinction clearly.