aboutsummaryrefslogtreecommitdiffhomepage
path: root/vendor/github.com/aws/aws-sdk-go/private/protocol/query
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/aws/aws-sdk-go/private/protocol/query')
-rw-r--r--vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go2
-rw-r--r--vendor/github.com/aws/aws-sdk-go/private/protocol/query/queryutil/queryutil.go11
2 files changed, 11 insertions, 2 deletions
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go
index 18169f0..60e5b09 100644
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go
+++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/build.go
@@ -25,7 +25,7 @@ func Build(r *request.Request) {
25 return 25 return
26 } 26 }
27 27
28 if r.ExpireTime == 0 { 28 if !r.IsPresigned() {
29 r.HTTPRequest.Method = "POST" 29 r.HTTPRequest.Method = "POST"
30 r.HTTPRequest.Header.Set("Content-Type", "application/x-www-form-urlencoded; charset=utf-8") 30 r.HTTPRequest.Header.Set("Content-Type", "application/x-www-form-urlencoded; charset=utf-8")
31 r.SetBufferBody([]byte(body.Encode())) 31 r.SetBufferBody([]byte(body.Encode()))
diff --git a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/queryutil/queryutil.go b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/queryutil/queryutil.go
index 524ca95..75866d0 100644
--- a/vendor/github.com/aws/aws-sdk-go/private/protocol/query/queryutil/queryutil.go
+++ b/vendor/github.com/aws/aws-sdk-go/private/protocol/query/queryutil/queryutil.go
@@ -121,6 +121,10 @@ func (q *queryParser) parseList(v url.Values, value reflect.Value, prefix string
121 return nil 121 return nil
122 } 122 }
123 123
124 if _, ok := value.Interface().([]byte); ok {
125 return q.parseScalar(v, value, prefix, tag)
126 }
127
124 // check for unflattened list member 128 // check for unflattened list member
125 if !q.isEC2 && tag.Get("flattened") == "" { 129 if !q.isEC2 && tag.Get("flattened") == "" {
126 if listName := tag.Get("locationNameList"); listName == "" { 130 if listName := tag.Get("locationNameList"); listName == "" {
@@ -229,7 +233,12 @@ func (q *queryParser) parseScalar(v url.Values, r reflect.Value, name string, ta
229 v.Set(name, strconv.FormatFloat(float64(value), 'f', -1, 32)) 233 v.Set(name, strconv.FormatFloat(float64(value), 'f', -1, 32))
230 case time.Time: 234 case time.Time:
231 const ISO8601UTC = "2006-01-02T15:04:05Z" 235 const ISO8601UTC = "2006-01-02T15:04:05Z"
232 v.Set(name, value.UTC().Format(ISO8601UTC)) 236 format := tag.Get("timestampFormat")
237 if len(format) == 0 {
238 format = protocol.ISO8601TimeFormatName
239 }
240
241 v.Set(name, protocol.FormatTime(format, value))
233 default: 242 default:
234 return fmt.Errorf("unsupported value for param %s: %v (%s)", name, r.Interface(), r.Type().Name()) 243 return fmt.Errorf("unsupported value for param %s: %v (%s)", name, r.Interface(), r.Type().Name())
235 } 244 }