Skip to content

Commit

Permalink
fix fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
gabrielggg committed Nov 11, 2024
1 parent cbf6bf7 commit 541c714
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions cmd/policy-assistant/pkg/cli/analyze.go
Original file line number Diff line number Diff line change
Expand Up @@ -352,17 +352,17 @@ func VerdictWalkthrough(policies *matcher.Policy, sourceWorkloadTraffic string,
}

// Special case handling for workload-specific traffic (internal vs. external)
if sourceInternal != nil {
if sourceInternal.Workload != "" {
podA = matcher.GetInternalPeerInfo(sourceInternal.Workload)
}
}

if destinationInternal != nil {
if destinationInternal.Workload != "" {
podB = matcher.GetInternalPeerInfo(destinationInternal.Workload)
}
}
if sourceInternal != nil {
if sourceInternal.Workload != "" {
podA = matcher.GetInternalPeerInfo(sourceInternal.Workload)
}
}

if destinationInternal != nil {
if destinationInternal.Workload != "" {
podB = matcher.GetInternalPeerInfo(destinationInternal.Workload)
}
}

// Append the resolved traffic to the allTraffic slice
allTraffic = append(allTraffic, matcher.CreateTraffic(podA, podB, traffic.ResolvedPort, string(traffic.Protocol)))
Expand Down

0 comments on commit 541c714

Please sign in to comment.