summaryrefslogtreecommitdiffstats
path: root/vendor/gopkg.in/olivere/elastic.v5/indices_delete_template.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/gopkg.in/olivere/elastic.v5/indices_delete_template.go')
-rw-r--r--vendor/gopkg.in/olivere/elastic.v5/indices_delete_template.go16
1 files changed, 11 insertions, 5 deletions
diff --git a/vendor/gopkg.in/olivere/elastic.v5/indices_delete_template.go b/vendor/gopkg.in/olivere/elastic.v5/indices_delete_template.go
index d1b88d4bb..0ea34cf89 100644
--- a/vendor/gopkg.in/olivere/elastic.v5/indices_delete_template.go
+++ b/vendor/gopkg.in/olivere/elastic.v5/indices_delete_template.go
@@ -9,11 +9,11 @@ import (
"fmt"
"net/url"
- "gopkg.in/olivere/elastic.v5/uritemplates"
+ "github.com/olivere/elastic/uritemplates"
)
// IndicesDeleteTemplateService deletes index templates.
-// See https://www.elastic.co/guide/en/elasticsearch/reference/5.2/indices-templates.html.
+// See https://www.elastic.co/guide/en/elasticsearch/reference/6.0/indices-templates.html.
type IndicesDeleteTemplateService struct {
client *Client
pretty bool
@@ -66,7 +66,7 @@ func (s *IndicesDeleteTemplateService) buildURL() (string, url.Values, error) {
// Add query string parameters
params := url.Values{}
if s.pretty {
- params.Set("pretty", "1")
+ params.Set("pretty", "true")
}
if s.timeout != "" {
params.Set("timeout", s.timeout)
@@ -103,7 +103,11 @@ func (s *IndicesDeleteTemplateService) Do(ctx context.Context) (*IndicesDeleteTe
}
// Get HTTP response
- res, err := s.client.PerformRequest(ctx, "DELETE", path, params, nil)
+ res, err := s.client.PerformRequest(ctx, PerformRequestOptions{
+ Method: "DELETE",
+ Path: path,
+ Params: params,
+ })
if err != nil {
return nil, err
}
@@ -118,5 +122,7 @@ func (s *IndicesDeleteTemplateService) Do(ctx context.Context) (*IndicesDeleteTe
// IndicesDeleteTemplateResponse is the response of IndicesDeleteTemplateService.Do.
type IndicesDeleteTemplateResponse struct {
- Acknowledged bool `json:"acknowledged,omitempty"`
+ Acknowledged bool `json:"acknowledged"`
+ ShardsAcknowledged bool `json:"shards_acknowledged"`
+ Index string `json:"index,omitempty"`
}