Skip to content

Commit

Permalink
Fix error in getting name from tags and add debug print statement
Browse files Browse the repository at this point in the history
  • Loading branch information
Roger Gomez committed Feb 28, 2024
1 parent 716f94b commit 049cb45
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 1 addition & 2 deletions aws/awsrouter/transit_gateway.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,8 +118,7 @@ func (t *Tgw) UpdateTgwRouteTablesAttachments(ctx context.Context, api ports.AWS
if len(tags) == 0 {
continue
}
name, err = GetNamesFromTags(tags)
if err != nil {
if name, err = GetNamesFromTags(tags); err != nil {
fmt.Println("error getting the name from the tags")
continue
}
Expand Down
3 changes: 3 additions & 0 deletions aws/awsrouter/transit_gateway_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ func ExportTgwRoutesExcel(tgws []*Tgw, folder fs.FileInfo) error {
}
state := fmt.Sprint(route.State)
routeType := fmt.Sprint(route.Type)
for _, attachment := range tgwRouteTable.Attachments {
fmt.Println(attachment)
}
var attachmentName = "-"
if len(route.TransitGatewayAttachments) != 0 {
attachmentID := fmt.Sprint(*route.TransitGatewayAttachments[0].TransitGatewayAttachmentId)
Expand Down

0 comments on commit 049cb45

Please sign in to comment.