Closed matiya closed 2 years ago
Describe the issue
Running the command: Get-PASSafeMember -SafeName ABC-001
Get-PASSafeMember -SafeName ABC-001
Returns all safe members as intended, for example:
UserName SafeName Permissions -------- -------- ----------- vaultadmin01 ACB-0001 @{useAccounts=True; retrieveAccounts=True; listAccounts=True; addAccounts=True; updateAccountCo…
With the -search parameter it works too:
Get-PASSafeMember -safe ABC-001 -search vaultadmin01 UserName SafeName Permissions -------- -------- ----------- vaultadmin01 ABC-0001 @{useAccounts=True; retrieveAccounts=True; listAccounts=True; addAccounts=True; updateAccountContent=True; updateA…
But if I add the parameter -MemberName, for instance: Get-PASSafeMember -SafeName ABC-0001 -MemberName vaultadmin01
Get-PASSafeMember -SafeName ABC-0001 -MemberName vaultadmin01
I get the following error:
MethodInvocationException: Line | 273 | … $Members = [Collections.Generic.List[Object]]::New(($resu … | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | Exception calling ".ctor" with "1" argument(s): "Value cannot be null. (Parameter 'collection')"
Your Environment Include relevant details about your environment
Thanks for the report @matiya . Issue reproduced in pwsh (issue not present in PowerShell). Fix developed and present in the dev branch.
Describe the issue
Running the command:
Get-PASSafeMember -SafeName ABC-001
Returns all safe members as intended, for example:
With the -search parameter it works too:
But if I add the parameter -MemberName, for instance:
Get-PASSafeMember -SafeName ABC-0001 -MemberName vaultadmin01
I get the following error:
Your Environment Include relevant details about your environment