From c765aec90673c96f25f3050eef5d6111a91f8c1e Mon Sep 17 00:00:00 2001 From: Sean McGinnis <sean.mcginnis@gmail.com> Date: Thu, 18 Apr 2024 16:04:31 -0500 Subject: [PATCH] Add CertificateLocations access to CertificateService Signed-off-by: Sean McGinnis <sean.mcginnis@gmail.com> --- redfish/certificateservice.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/redfish/certificateservice.go b/redfish/certificateservice.go index da4eb807..216bedd5 100644 --- a/redfish/certificateservice.go +++ b/redfish/certificateservice.go @@ -60,6 +60,14 @@ func (certificateservice *CertificateService) UnmarshalJSON(b []byte) error { return nil } +// CertificateLocations get the certificate locations. +func (certificateservice *CertificateService) CertificateLocations() (*CertificateLocations, error) { + if certificateservice.certificateLocations == "" { + return nil, nil + } + return GetCertificateLocations(certificateservice.GetClient(), certificateservice.certificateLocations) +} + // GetCertificateService will get a CertificateService instance from the service. func GetCertificateService(c common.Client, uri string) (*CertificateService, error) { resp, err := c.Get(uri)