CSI: fix URL for volume snapshot list

This commit is contained in:
Tim Gross 2021-04-07 09:28:08 -04:00 committed by Tim Gross
parent e4f34a96e3
commit d2d12b201c
3 changed files with 3 additions and 3 deletions

View File

@ -151,7 +151,7 @@ func (v *CSIVolumes) ListSnapshots(pluginID string, q *QueryOptions) (*CSISnapsh
qp.Set("per_page", fmt.Sprint(q.PerPage))
}
qm, err := v.client.query("/v1/volumes/snapshots?"+qp.Encode(), &resp, q)
qm, err := v.client.query("/v1/volumes/snapshot?"+qp.Encode(), &resp, q)
if err != nil {
return nil, nil, err
}

View File

@ -122,7 +122,7 @@ func (c *VolumeSnapshotListCommand) Run(args []string) int {
resp, _, err := client.CSIVolumes().ListSnapshots(pluginID, q)
if err != nil {
c.Ui.Error(fmt.Sprintf(
"Error querying CSI external volumes for plugin %q: %s", pluginID, err))
"Error querying CSI external snapshots for plugin %q: %s", pluginID, err))
return 1
}
if len(resp.Snapshots) > 0 {

View File

@ -151,7 +151,7 @@ func (v *CSIVolumes) ListSnapshots(pluginID string, q *QueryOptions) (*CSISnapsh
qp.Set("per_page", fmt.Sprint(q.PerPage))
}
qm, err := v.client.query("/v1/volumes/snapshots?"+qp.Encode(), &resp, q)
qm, err := v.client.query("/v1/volumes/snapshot?"+qp.Encode(), &resp, q)
if err != nil {
return nil, nil, err
}