diff --git a/plugin/api/index_management/index.go b/plugin/api/index_management/index.go index 3c0be5e6..6c659afd 100644 --- a/plugin/api/index_management/index.go +++ b/plugin/api/index_management/index.go @@ -123,7 +123,12 @@ func (h APIHandler) ListIndex(w http.ResponseWriter, req *http.Request, ps httpr keyword := h.GetParameterOrDefault(req, "keyword", "") ids := strings.Split(clusterIds, ",") for i := range ids { - ids[i] = `"` + ids[i] + `"` + if i < len(ids)-1 { + ids[i] = `"` + ids[i] + `",` + } else { + ids[i] = `"` + ids[i] + `"` + } + } if len(ids) == 0 { h.Error400(w, "id is required")