Skip to content

Commit 77604c6

Browse files
committed
refactor: fix misleading var naming
1 parent e6221df commit 77604c6

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

hcloud/routes.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,10 +130,10 @@ func (r *routes) CreateRoute(ctx context.Context, _ string, _ string, route *clo
130130
return fmt.Errorf("%s: %w", op, err)
131131
}
132132

133-
clusterNetSize, _ := r.clusterCIDR.Mask.Size()
134-
destNetSize, _ := cidr.Mask.Size()
133+
clusterPrefixLen, _ := r.clusterCIDR.Mask.Size()
134+
destPrefixLen, _ := cidr.Mask.Size()
135135

136-
if !r.clusterCIDR.Contains(cidr.IP) || destNetSize < clusterNetSize {
136+
if !r.clusterCIDR.Contains(cidr.IP) || destPrefixLen < clusterPrefixLen {
137137
node := &corev1.Node{
138138
ObjectMeta: metav1.ObjectMeta{
139139
Name: string(route.TargetNode),

0 commit comments

Comments
 (0)