Skip to content

Commit

Permalink
fixed some lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
wilkermichael committed Sep 22, 2023
1 parent 1276430 commit 9c4fb95
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions control-plane/connect-inject/common/annotation_processor.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@ const (
ConsulNodeAddress = "127.0.0.1"
)

// PodAnnotationProcessor processes a pod annotation into pbmesh.Upstreams
// PodAnnotationProcessor processes a pod annotation into pbmesh.Upstreams.
type PodAnnotationProcessor struct {
enablePartitions bool
enableNamespaces bool
}

// NewPodAnnotationProcessor constructs a PodAnnotationProcessor for processing pod annotations into pbmesh.Upsreams
// NewPodAnnotationProcessor constructs a PodAnnotationProcessor for processing pod annotations into pbmesh.Upsreams.
func NewPodAnnotationProcessor(enablePartitions, enableNamespaces bool) PodAnnotationProcessor {
return PodAnnotationProcessor{
enablePartitions: enablePartitions,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -964,7 +964,7 @@ func TestUpstreamRefrenceType(t *testing.T) {
Kind: "Service",
}
actual := UpstreamReferenceType()
require.Equal(t, *actual, *expect)
require.Equal(t, actual, expect)
}

// createPod creates a multi-port pod as a base for tests.
Expand Down
6 changes: 3 additions & 3 deletions control-plane/connect-inject/constants/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ const (
)

// GetDefaultConsulNamespace returns the default namespace if the passed namespace
// is empty, otherwise returns back the passed in namespace
// is empty, otherwise returns back the passed in namespace.
func GetDefaultConsulNamespace(ns string) string {
if ns == "" {
ns = DefaultConsulNS
Expand All @@ -66,7 +66,7 @@ func GetDefaultConsulNamespace(ns string) string {
}

// GetDefaultConsulPartition returns the default partition if the passed partition
// is empty, otherwise returns back the passed in partition
// is empty, otherwise returns back the passed in partition.
func GetDefaultConsulPartition(ap string) string {
if ap == "" {
ap = DefaultConsulPartition
Expand All @@ -76,7 +76,7 @@ func GetDefaultConsulPartition(ap string) string {
}

// GetDefaultConsulPeer returns the default peer if the passed peer
// is empty, otherwise returns back the passed in peer
// is empty, otherwise returns back the passed in peer.
func GetDefaultConsulPeer(peer string) string {
if peer == "" {
peer = DefaultConsulPeer
Expand Down

0 comments on commit 9c4fb95

Please sign in to comment.