Skip to content
Permalink
Browse files
Fix usersecuritygrouplist parameters (#66)
  • Loading branch information
Sander van Harmelen committed Oct 23, 2016
1 parent 7d6a444 commit 5e674b6b5bcabb763a329a55812d7331771d5b78
Showing 2 changed files with 4 additions and 4 deletions.
@@ -333,8 +333,7 @@ func (p *AuthorizeSecurityGroupIngressParams) toURLValues() url.Values {
if v, found := p.p["usersecuritygrouplist"]; found {
i := 0
for k, vv := range v.(map[string]string) {
u.Set(fmt.Sprintf("usersecuritygrouplist[%d].key", i), k)
u.Set(fmt.Sprintf("usersecuritygrouplist[%d].value", i), vv)
u.Set(fmt.Sprintf("usersecuritygrouplist[%d].%s", i, k), vv)
i++
}
}
@@ -621,8 +620,7 @@ func (p *AuthorizeSecurityGroupEgressParams) toURLValues() url.Values {
if v, found := p.p["usersecuritygrouplist"]; found {
i := 0
for k, vv := range v.(map[string]string) {
u.Set(fmt.Sprintf("usersecuritygrouplist[%d].key", i), k)
u.Set(fmt.Sprintf("usersecuritygrouplist[%d].value", i), vv)
u.Set(fmt.Sprintf("usersecuritygrouplist[%d].%s", i, k), vv)
i++
}
}
@@ -689,6 +689,8 @@ func (s *service) generateConvertCode(name, typ string) {
case "serviceproviderlist":
pn(" u.Set(fmt.Sprintf(\"%s[%%d].service\", i), k)", name)
pn(" u.Set(fmt.Sprintf(\"%s[%%d].provider\", i), vv)", name)
case "usersecuritygrouplist":
pn(" u.Set(fmt.Sprintf(\"%s[%%d].%%s\", i, k), vv)", name)
default:
pn(" u.Set(fmt.Sprintf(\"%s[%%d].key\", i), k)", name)
pn(" u.Set(fmt.Sprintf(\"%s[%%d].value\", i), vv)", name)

0 comments on commit 5e674b6

Please sign in to comment.