apache / cloudstack-go

CloudStack Go SDK

Home Page:https://cloudstack.apache.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

DomainService Fails to Unmarshal DomainChildren

rejoshed opened this issue · comments

Hello,

In using CS-Go, I noticed that listDomainChildren fails to unmarshal DomainChildren.

I modified the JSON tag and it worked perfectly.

    DomainChildren []*DomainChildren `json:"domain"`

I don't know if this is an issue across all versions of the CloudStack API. I personally work against 4.16.

I'd be happy to PR a change, but again I'm not sure if it would be backward compatible with older API versions.

Also, should it be considered an error if unmarshalling fails? I sort of think so.

@rejoshed Can you please use the v2.13.1 tag. The fix has been added