Skip to content

Commit 92343a6

Browse files
committed
Zone and Pod update responses aren't being processed the same as other updates
1 parent 16260d4 commit 92343a6

File tree

4 files changed

+16
-1
lines changed

4 files changed

+16
-1
lines changed

README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,14 @@ The `listAPIs.json` file holds the output of `listApis` command for a specific r
6464
```
6565
# Run it via the Makefile
6666
make all
67-
6867
```
6968

69+
### Prerequisites
70+
71+
* `goimports`: Install by running `go install golang.org/x/tools/cmd/goimports@latest`
72+
73+
* `mockgen`: Install by running `go install go.uber.org/mock/mockgen@latest`
74+
7075
## Getting Help
7176

7277
_Please try to see if the [module documentation](https://pkg.go.dev/github.com/apache/cloudstack-go/v2/cloudstack) can provide some answers first!_

cloudstack/PodService.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1830,6 +1830,10 @@ func (s *PodService) UpdatePod(p *UpdatePodParams) (*UpdatePodResponse, error) {
18301830
return nil, err
18311831
}
18321832

1833+
if resp, err = getRawValue(resp); err != nil {
1834+
return nil, err
1835+
}
1836+
18331837
var r UpdatePodResponse
18341838
if err := json.Unmarshal(resp, &r); err != nil {
18351839
return nil, err

cloudstack/ZoneService.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3691,6 +3691,10 @@ func (s *ZoneService) UpdateZone(p *UpdateZoneParams) (*UpdateZoneResponse, erro
36913691
return nil, err
36923692
}
36933693

3694+
if resp, err = getRawValue(resp); err != nil {
3695+
return nil, err
3696+
}
3697+
36943698
var r UpdateZoneResponse
36953699
if err := json.Unmarshal(resp, &r); err != nil {
36963700
return nil, err

generate/generate.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1794,11 +1794,13 @@ func (s *service) generateNewAPICallFunc(a *API) {
17941794
"UpdateCluster",
17951795
"UpdateVlanIpRange",
17961796
"CreatePod",
1797+
"UpdatePod",
17971798
"CreateSSHKeyPair",
17981799
"CreateSecurityGroup",
17991800
"CreateServiceOffering",
18001801
"CreateUser",
18011802
"CreateZone",
1803+
"UpdateZone",
18021804
"DedicateGuestVlanRange",
18031805
"EnableUser",
18041806
"GetVirtualMachineUserData",

0 commit comments

Comments
 (0)