From 42fd15d54c116c13a67e382e8ae6d2df362a19cc Mon Sep 17 00:00:00 2001 From: delvedor Date: Fri, 2 Nov 2018 11:46:00 +0100 Subject: [PATCH] API generation --- api/api/cluster.stats.js | 2 +- api/api/indices.delete_alias.js | 2 +- api/api/indices.put_alias.js | 2 +- api/api/nodes.hot_threads.js | 2 +- api/api/reindex_rethrottle.js | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/api/api/cluster.stats.js b/api/api/cluster.stats.js index efc361d97..d674a491d 100644 --- a/api/api/cluster.stats.js +++ b/api/api/cluster.stats.js @@ -90,7 +90,7 @@ function buildClusterStats (opts) { const request = { method, path: (params['node_id'] || params['nodeId']) != null - ? '/' + parts.filter(Boolean).join('/') + ? '/' + parts.filter(Boolean).map(encodeURIComponent).join('/') : '/_cluster/stats', querystring, body: null, diff --git a/api/api/indices.delete_alias.js b/api/api/indices.delete_alias.js index 7da283f68..b876b8eec 100644 --- a/api/api/indices.delete_alias.js +++ b/api/api/indices.delete_alias.js @@ -111,7 +111,7 @@ function buildIndicesDeleteAlias (opts) { const request = { method, path: params['index'] != null && params['name'] != null - ? '/' + parts.filter(Boolean).join('/') + ? '/' + parts.filter(Boolean).map(encodeURIComponent).join('/') : '/{index}/_alias/{name}', querystring, body: '', diff --git a/api/api/indices.put_alias.js b/api/api/indices.put_alias.js index fce99f4cb..d0efccf94 100644 --- a/api/api/indices.put_alias.js +++ b/api/api/indices.put_alias.js @@ -106,7 +106,7 @@ function buildIndicesPutAlias (opts) { const request = { method, path: params['index'] != null && params['name'] != null - ? '/' + parts.filter(Boolean).join('/') + ? '/' + parts.filter(Boolean).map(encodeURIComponent).join('/') : '/{index}/_alias/{name}', querystring, body: params.body || '', diff --git a/api/api/nodes.hot_threads.js b/api/api/nodes.hot_threads.js index 6dcf89610..23ac7e02d 100644 --- a/api/api/nodes.hot_threads.js +++ b/api/api/nodes.hot_threads.js @@ -102,7 +102,7 @@ function buildNodesHotThreads (opts) { const request = { method, path: (params['node_id'] || params['nodeId']) != null - ? '/' + parts.filter(Boolean).join('/') + ? '/' + parts.filter(Boolean).map(encodeURIComponent).join('/') : '/_nodes/hot_threads', querystring, body: null, diff --git a/api/api/reindex_rethrottle.js b/api/api/reindex_rethrottle.js index caa50c151..396dff3d1 100644 --- a/api/api/reindex_rethrottle.js +++ b/api/api/reindex_rethrottle.js @@ -99,7 +99,7 @@ function buildReindexRethrottle (opts) { const request = { method, path: (params['task_id'] || params['taskId']) != null - ? '/' + parts.filter(Boolean).join('/') + ? '/' + parts.filter(Boolean).map(encodeURIComponent).join('/') : '/_reindex/{task_id}/_rethrottle', querystring, body: '',