Skip to content

Commit

Permalink
Rename generateSecret to populateSecret
Browse files Browse the repository at this point in the history
Signed-off-by: cmoulliard <[email protected]>
  • Loading branch information
cmoulliard committed Dec 20, 2024
1 parent 771fd89 commit 813c0cd
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions pkg/cmd/get/secrets.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ func printAllPackageSecrets(ctx context.Context, outWriter io.Writer, kubeClient
}
return fmt.Errorf("getting secret %s in %s: %w", v[i], k, sErr)
}
secrets = append(secrets, generateSecret(secret, true))
secrets = append(secrets, populateSecret(secret, true))
}
}

Expand All @@ -113,7 +113,7 @@ func printAllPackageSecrets(ctx context.Context, outWriter io.Writer, kubeClient
}

for i := range cnoeLabelSecrets.Items {
secrets = append(secrets, generateSecret(cnoeLabelSecrets.Items[i], false))
secrets = append(secrets, populateSecret(cnoeLabelSecrets.Items[i], false))
}

if len(secrets) == 0 {
Expand All @@ -139,7 +139,7 @@ func printPackageSecrets(ctx context.Context, outWriter io.Writer, kubeClient cl
}
return fmt.Errorf("getting secret %s in %s: %w", secretNames[j], p, sErr)
}
secrets = append(secrets, generateSecret(secret, true))
secrets = append(secrets, populateSecret(secret, true))
}
continue
}
Expand All @@ -157,7 +157,7 @@ func printPackageSecrets(ctx context.Context, outWriter io.Writer, kubeClient cl
}

for i := range cnoeLabelSecrets.Items {
secrets = append(secrets, generateSecret(cnoeLabelSecrets.Items[i], false))
secrets = append(secrets, populateSecret(cnoeLabelSecrets.Items[i], false))
}

if len(secrets) == 0 {
Expand Down Expand Up @@ -216,7 +216,7 @@ func printSecretsOutput(outWriter io.Writer, secrets []Secret, format string) er
}
}

func generateSecret(s v1.Secret, isCoreSecret bool) Secret {
func populateSecret(s v1.Secret, isCoreSecret bool) Secret {
secret := Secret{
Name: s.Name,
Namespace: s.Namespace,
Expand Down

0 comments on commit 813c0cd

Please sign in to comment.