Skip to content

Commit

Permalink
Deploying from phrase/openapi@8ce0253f
Browse files Browse the repository at this point in the history
  • Loading branch information
Phrase committed Dec 21, 2023
1 parent 824f570 commit b799535
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions client.go
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,8 @@ func parameterToJson(obj interface{}) (string, error) {
// helper for serializing and setting mapped parameters request body
func serializeMapParams(key string, value interface{}, localParams url.Values) url.Values {
if reflect.TypeOf(value).Kind() == reflect.Map {

// since we allow values of type interface, type assertion is necessary
for k, v := range value.(map[string]interface{}) {
paramKeyName := fmt.Sprintf("%s[%s]", key, k)
serializeMapParams(paramKeyName, v, localParams)
Expand Down

0 comments on commit b799535

Please sign in to comment.