Skip to content

Commit

Permalink
Updates function comments
Browse files Browse the repository at this point in the history
  • Loading branch information
gdavison committed Apr 28, 2021
1 parent 3494b25 commit 2f7a24f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion aws/internal/service/ec2/finder/finder.go
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,6 @@ func RouteByPrefixListIDDestination(conn *ec2.EC2, routeTableID, prefixListID st
return nil, &resource.NotFoundError{}
}

// SecurityGroupByID looks up a security group by ID. When not found, returns nil and potentially an API error.
// SecurityGroupByID looks up a security group by ID. Returns a resource.NotFoundError if not found.
func SecurityGroupByID(conn *ec2.EC2, id string) (*ec2.SecurityGroup, error) {
input := &ec2.DescribeSecurityGroupsInput{
Expand All @@ -348,6 +347,7 @@ func SecurityGroupByNameAndVpcID(conn *ec2.EC2, name, vpcID string) (*ec2.Securi
return SecurityGroup(conn, input)
}

// SecurityGroup looks up a security group using an ec2.DescribeSecurityGroupsInput. Returns a resource.NotFoundError if not found.
func SecurityGroup(conn *ec2.EC2, input *ec2.DescribeSecurityGroupsInput) (*ec2.SecurityGroup, error) {
result, err := conn.DescribeSecurityGroups(input)
if tfawserr.ErrCodeEquals(err, tfec2.InvalidSecurityGroupIDNotFound) ||
Expand Down

0 comments on commit 2f7a24f

Please sign in to comment.