vmware / powershell-module-for-vmware-cloud-foundation-password-management

PowerShell Module for VMware Cloud Foundation Password Management
https://vmware.github.io/powershell-module-for-vmware-cloud-foundation-password-management/
BSD 2-Clause "Simplified" License
11 stars 9 forks source link

`Publish-*` functions will not convert to json when `-json` parameter is used #193

Closed bhumitra closed 3 months ago

bhumitra commented 4 months ago

Code of Conduct

VMware Cloud Foundation

5.1

PowerShell Version

7.2

PowerCLI Version

v13.1.0

Module Version

1.8

PowerValidatedSolutions Version

2.9.0

PowerVCF Version

2.4.1

Guest Operating System

Windows Server 2019

Environment Details

No response

Description

All the publish commandlets are currently configured to return the PSObject without converting to json -

see this as an example

 if ($PsBoundParameters.ContainsKey('json')) {
    $allSddcManagerPasswordExpirationObject
 } 

It should rather return:

$allSddcManagerPasswordExpirationObject | ConvertTo-Json

This change is required for all the Publish-* functions.

Error or Debug Output

See description.

Expected Behavior

See description.

Actual Behavior

See description.

Steps to Reproduce

See description.

Log Fragments and Files

No response

Screenshots

No response

References

No response

github-actions[bot] commented 2 months ago

I'm going to lock this issue because it has been closed for 30 days. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.