Skip to content

Commit

Permalink
make lint happy
Browse files Browse the repository at this point in the history
  • Loading branch information
ShiriMoran committed Aug 15, 2023
1 parent 0db151c commit 6db386c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
10 changes: 3 additions & 7 deletions pkg/vpcmodel/grouping.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,17 +169,13 @@ func (g *GroupConnLines) groupExternalAddressesForSubnets() {
continue
}
connString := conns.EnhancedString()
hasExternal := false
switch dst.(type) {
case Node:
if dst.(Node).IsPublicInternet() {
hasExternal = true
g.srcToDst.addPublicConnectivity(src, connString, dst.(Node))
}
}
// connection is to the internet; this and connection between subnets are the only types being analyzed here
g.srcToDst.addPublicConnectivity(src, connString, dst.(Node))
// since pgw enable only egress src can not be public internet
// not an external connection in source or destination - nothing to group, just append
if !hasExternal {
default:
res = append(res, &GroupedConnLine{src, dst, connString})
}
}
Expand Down
3 changes: 2 additions & 1 deletion pkg/vpcmodel/subnetsConnectivity.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
package vpcmodel

import (
"github.com/np-guard/vpc-network-config-analyzer/pkg/common"

"errors"
"fmt"
"github.com/np-guard/vpc-network-config-analyzer/pkg/common"
)

// VPCsubnetConnectivity captures allowed connectivity for subnets, considering nacl and pgw resources
Expand Down

0 comments on commit 6db386c

Please sign in to comment.