Skip to content

Commit 7c9a042

Browse files
committed
refactor: rename k8stypes -> ktypes
1 parent fdf44c3 commit 7c9a042

2 files changed

Lines changed: 7 additions & 7 deletions

File tree

internal/validators/iam/iam_validator.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import (
1111
"github.com/go-logr/logr"
1212
"golang.org/x/exp/slices"
1313
corev1 "k8s.io/api/core/v1"
14-
k8stypes "k8s.io/apimachinery/pkg/types"
14+
ktypes "k8s.io/apimachinery/pkg/types"
1515

1616
"github.com/spectrocloud-labs/valid8or-plugin-aws/api/v1alpha1"
1717
"github.com/spectrocloud-labs/valid8or-plugin-aws/internal/constants"
@@ -66,7 +66,7 @@ func NewIAMRuleService(log logr.Logger, s *session.Session) *IAMRuleService {
6666
}
6767

6868
// ReconcileIAMRoleRule reconciles an IAM role validation rule from an AWSValidator config
69-
func (s *IAMRuleService) ReconcileIAMRoleRule(nn k8stypes.NamespacedName, rule iamRule) (*types.ValidationResult, error) {
69+
func (s *IAMRuleService) ReconcileIAMRoleRule(nn ktypes.NamespacedName, rule iamRule) (*types.ValidationResult, error) {
7070

7171
// Build the default ValidationResult for this IAM rule
7272
vr := buildValidationResult(rule, constants.ValidationTypeIAMRolePolicy)
@@ -96,7 +96,7 @@ func (s *IAMRuleService) ReconcileIAMRoleRule(nn k8stypes.NamespacedName, rule i
9696
}
9797

9898
// ReconcileIAMUserRule reconciles an IAM user validation rule from an AWSValidator config
99-
func (s *IAMRuleService) ReconcileIAMUserRule(nn k8stypes.NamespacedName, rule iamRule) (*types.ValidationResult, error) {
99+
func (s *IAMRuleService) ReconcileIAMUserRule(nn ktypes.NamespacedName, rule iamRule) (*types.ValidationResult, error) {
100100

101101
// Build the default ValidationResult for this IAM rule
102102
vr := buildValidationResult(rule, constants.ValidationTypeIAMUserPolicy)
@@ -126,7 +126,7 @@ func (s *IAMRuleService) ReconcileIAMUserRule(nn k8stypes.NamespacedName, rule i
126126
}
127127

128128
// ReconcileIAMGroupRule reconciles an IAM group validation rule from an AWSValidator config
129-
func (s *IAMRuleService) ReconcileIAMGroupRule(nn k8stypes.NamespacedName, rule iamRule) (*types.ValidationResult, error) {
129+
func (s *IAMRuleService) ReconcileIAMGroupRule(nn ktypes.NamespacedName, rule iamRule) (*types.ValidationResult, error) {
130130

131131
// Build the default ValidationResult for this IAM rule
132132
vr := buildValidationResult(rule, constants.ValidationTypeIAMGroupPolicy)
@@ -156,7 +156,7 @@ func (s *IAMRuleService) ReconcileIAMGroupRule(nn k8stypes.NamespacedName, rule
156156
}
157157

158158
// ReconcileIAMPolicyRule reconciles an IAM policy validation rule from an AWSValidator config
159-
func (s *IAMRuleService) ReconcileIAMPolicyRule(nn k8stypes.NamespacedName, rule iamRule) (*types.ValidationResult, error) {
159+
func (s *IAMRuleService) ReconcileIAMPolicyRule(nn ktypes.NamespacedName, rule iamRule) (*types.ValidationResult, error) {
160160

161161
// Build the default ValidationResult for this IAM rule
162162
vr := buildValidationResult(rule, constants.ValidationTypeIAMPolicy)

internal/validators/tag/tag_validator.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import (
77
"github.com/aws/aws-sdk-go/service/ec2"
88
"github.com/go-logr/logr"
99
corev1 "k8s.io/api/core/v1"
10-
k8stypes "k8s.io/apimachinery/pkg/types"
10+
ktypes "k8s.io/apimachinery/pkg/types"
1111

1212
"github.com/spectrocloud-labs/valid8or-plugin-aws/api/v1alpha1"
1313
"github.com/spectrocloud-labs/valid8or-plugin-aws/internal/constants"
@@ -31,7 +31,7 @@ func NewTagRuleService(log logr.Logger, s *session.Session) *TagRuleService {
3131
}
3232

3333
// ReconcileTagRule reconciles an EC2 tagging validation rule from the AWSValidator config
34-
func (s *TagRuleService) ReconcileTagRule(nn k8stypes.NamespacedName, rule v1alpha1.TagRule) (*v8ortypes.ValidationResult, error) {
34+
func (s *TagRuleService) ReconcileTagRule(nn ktypes.NamespacedName, rule v1alpha1.TagRule) (*v8ortypes.ValidationResult, error) {
3535
ec2Svc := aws.EC2Service(s.session, rule.Region)
3636

3737
// Build the default latest condition for this tag rule

0 commit comments

Comments
 (0)