Skip to content

Commit

Permalink
[Bug] Fix #296
Browse files Browse the repository at this point in the history
  • Loading branch information
derailed committed Mar 16, 2024
1 parent c872179 commit f43ad34
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion internal/lint/svc.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,11 @@ func (s *Service) checkEndpoints(ctx context.Context, fqn string, kind v1.Servic
s.AddCode(ctx, 1110)
return
}
if len(ep.Subsets) == 1 {
var eps int
for _, s := range ep.Subsets {
eps += len(s.Addresses)
}
if eps == 1 {
s.AddCode(ctx, 1109)
}
}
Expand Down

0 comments on commit f43ad34

Please sign in to comment.