update comments

This commit is contained in:
clint shryock 2016-03-09 15:50:01 -06:00
parent 23c42cd6cf
commit f96ec46681
1 changed files with 4 additions and 0 deletions

View File

@ -329,6 +329,7 @@ func flattenSecurityGroups(list []*ec2.UserIdGroupPair, ownerId *string) []*ec2.
if g.UserId != nil && *g.UserId != "" && (ownerId == nil || *ownerId != *g.UserId) {
userId = g.UserId
}
// userid nil here for same vpc groups
vpc := g.GroupName == nil || *g.GroupName == ""
var id *string
@ -338,6 +339,9 @@ func flattenSecurityGroups(list []*ec2.UserIdGroupPair, ownerId *string) []*ec2.
id = g.GroupName
}
// id is groupid for vpcs
// id is groupname for non vpc (classic)
if userId != nil {
id = aws.String(*userId + "/" + *id)
}