Skip to content

Commit dfcc37b

Browse files
authored
chore: unnecessary use of fmt.Sprintf
1 parent 77ab954 commit dfcc37b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pkg/kube/netpol/policies.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -614,7 +614,7 @@ spec:
614614
func AllowNoEgressFromNamespace(namespace string) *networkingv1.NetworkPolicy {
615615
return &networkingv1.NetworkPolicy{
616616
ObjectMeta: metav1.ObjectMeta{
617-
Name: fmt.Sprintf("allow-no-egress-from-namespace"),
617+
Name: "allow-no-egress-from-namespace",
618618
Namespace: namespace,
619619
},
620620
Spec: networkingv1.NetworkPolicySpec{
@@ -695,7 +695,7 @@ spec:
695695
func AllowNoIngressNorEgress(namespace string, targetLabels map[string]string) *networkingv1.NetworkPolicy {
696696
return &networkingv1.NetworkPolicy{
697697
ObjectMeta: metav1.ObjectMeta{
698-
Name: fmt.Sprintf("allow-nothing"),
698+
Name: "allow-nothing",
699699
Namespace: namespace,
700700
},
701701
Spec: networkingv1.NetworkPolicySpec{

0 commit comments

Comments
 (0)