Skip to content

Commit 77a16a5

Browse files
authored
fix: Update GetMonitors function to unmarshal response into GetMonitorsResponse struct (#19)
2 parents 254c525 + dd2a704 commit 77a16a5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

komodor/monitors.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,9 +93,9 @@ func (c *Client) GetMonitors() ([]Monitor, error) {
9393
return nil, err
9494
}
9595

96-
var monitors []Monitor
96+
var response GetMonitorsResponse
9797

98-
err = json.Unmarshal(res, &monitors)
98+
err = json.Unmarshal(res, &response)
9999
if err != nil {
100100
return nil, err
101101
}

0 commit comments

Comments
 (0)