From 528604359c20a32fef628d86abdb7663e81235c3 Mon Sep 17 00:00:00 2001 From: Jeff Mitchell Date: Fri, 8 Mar 2019 14:14:50 -0500 Subject: [PATCH] Stop some curl whining (#6385) GET is inferred, so make curl whine less by not printing it --- api/output_string.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/api/output_string.go b/api/output_string.go index ebfdad6c0d..b836b77a5a 100644 --- a/api/output_string.go +++ b/api/output_string.go @@ -41,7 +41,9 @@ func (d *OutputStringError) parseRequest() { // Build cURL string d.parsedCurlString = "curl " - d.parsedCurlString = fmt.Sprintf("%s-X %s ", d.parsedCurlString, d.Request.Method) + if d.Request.Method != "GET" { + d.parsedCurlString = fmt.Sprintf("%s-X %s ", d.parsedCurlString, d.Request.Method) + } for k, v := range d.Request.Header { for _, h := range v { if strings.ToLower(k) == "x-vault-token" {