Skip to content

Commit bcb5aba

Browse files
authored
Merge pull request ekristen#608 from apgrucza/fix-private-api-domain-tags-error
2 parents bbeaf78 + 100bb6b commit bcb5aba

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

resources/apigateway-domain-name.go

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ package resources
22

33
import (
44
"context"
5-
"fmt"
65

76
"github.com/gotidy/ptr"
87

@@ -50,12 +49,11 @@ func (l *APIGatewayDomainNameLister) List(ctx context.Context, o interface{}) ([
5049

5150
// Get tags for the domain
5251
tagsOutput, err := svc.GetTags(ctx, &apigateway.GetTagsInput{
53-
ResourceArn: ptr.String(fmt.Sprintf("arn:aws:apigateway:%s::/domainnames/%s", opts.Config.Region, *item.DomainName)),
52+
ResourceArn: item.DomainNameArn,
5453
})
5554
if err != nil {
5655
opts.Logger.WithError(err).Error("failed to get tags for domain")
57-
}
58-
if tagsOutput.Tags != nil {
56+
} else if tagsOutput.Tags != nil {
5957
tags = tagsOutput.Tags
6058
}
6159

0 commit comments

Comments
 (0)