Skip to content

Commit ffda93c

Browse files
committed
refactor: avoid abbreviations in function name
1 parent bf2d41f commit ffda93c

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed

pkg/handlers/generic/lifecycle/ccm/nutanix/handler.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ func (p *provider) Apply(
9898
// However, that would leave the credentials visible in the HelmChartProxy.
9999
// Instead, we'll create the Secret on the remote cluster and reference it in the Helm values.
100100
if clusterConfig.Addons.CCM.Credentials != nil {
101-
err = handlersutils.EnsureOwnerRefForSecret(
101+
err = handlersutils.EnsureOwnerReferenceForSecret(
102102
ctx,
103103
p.client,
104104
clusterConfig.Addons.CCM.Credentials.SecretRef.Name,

pkg/handlers/generic/lifecycle/csi/nutanix-csi/handler.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ func (n *NutanixCSI) Apply(
9797
}
9898

9999
if provider.Credentials != nil {
100-
err := handlersutils.EnsureOwnerRefForSecret(
100+
err := handlersutils.EnsureOwnerReferenceForSecret(
101101
ctx,
102102
n.client,
103103
provider.Credentials.SecretRef.Name,

pkg/handlers/generic/mutation/imageregistries/credentials/inject.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ func (h *imageRegistriesPatchHandler) Mutate(
129129
if secretName := secretNameForImageRegistryCredentials(imageRegistry.Credentials); secretName != "" {
130130
// Ensure the Secret is owned by the Cluster so it is correctly moved and deleted with the Cluster.
131131
// This code assumes that Secret exists and that was validated before calling this function.
132-
err := handlersutils.EnsureOwnerRefForSecret(
132+
err := handlersutils.EnsureOwnerReferenceForSecret(
133133
ctx,
134134
h.client,
135135
secretName,
@@ -162,7 +162,7 @@ func (h *imageRegistriesPatchHandler) Mutate(
162162
if secretName := secretNameForImageRegistryCredentials(globalMirror.Credentials); secretName != "" {
163163
// Ensure the Secret is owned by the Cluster so it is correctly moved and deleted with the Cluster.
164164
// This code assumes that Secret exists and that was validated before calling this function.
165-
err := handlersutils.EnsureOwnerRefForSecret(
165+
err := handlersutils.EnsureOwnerReferenceForSecret(
166166
ctx,
167167
h.client,
168168
secretName,

pkg/handlers/utils/secrets.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,8 @@ func CopySecretToRemoteCluster(
6363
return nil
6464
}
6565

66-
// EnsureOwnerRefForSecret will ensure that the secretName Secret has an OwnerReference of the cluster.
67-
func EnsureOwnerRefForSecret(
66+
// EnsureOwnerReferenceForSecret will ensure that the secretName Secret has an OwnerReference of the cluster.
67+
func EnsureOwnerReferenceForSecret(
6868
ctx context.Context,
6969
cl ctrlclient.Client,
7070
secretName string,

pkg/handlers/utils/secrets_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ func Test_EnsureOwnerRefForSecret(t *testing.T) {
104104
t.Run(tt.name, func(t *testing.T) {
105105
t.Parallel()
106106

107-
err := EnsureOwnerRefForSecret(
107+
err := EnsureOwnerReferenceForSecret(
108108
context.Background(),
109109
tt.client,
110110
tt.secretName,

0 commit comments

Comments
 (0)