mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 19:31:44 +00:00
[Azure] remove unncessary nil check for range
This commit is contained in:
parent
c70e3e93bd
commit
a0c2af4fcd
@ -265,7 +265,6 @@ func (az *Cloud) getServiceLoadBalancer(service *v1.Service, clusterName string,
|
|||||||
}
|
}
|
||||||
|
|
||||||
// check if the service already has a load balancer
|
// check if the service already has a load balancer
|
||||||
if existingLBs != nil {
|
|
||||||
for i := range existingLBs {
|
for i := range existingLBs {
|
||||||
existingLB := existingLBs[i]
|
existingLB := existingLBs[i]
|
||||||
if strings.EqualFold(*existingLB.Name, defaultLBName) {
|
if strings.EqualFold(*existingLB.Name, defaultLBName) {
|
||||||
@ -285,7 +284,6 @@ func (az *Cloud) getServiceLoadBalancer(service *v1.Service, clusterName string,
|
|||||||
|
|
||||||
return &existingLB, status, true, nil
|
return &existingLB, status, true, nil
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
hasMode, _, _ := getServiceLoadBalancerMode(service)
|
hasMode, _, _ := getServiceLoadBalancerMode(service)
|
||||||
if az.useStandardLoadBalancer() && hasMode {
|
if az.useStandardLoadBalancer() && hasMode {
|
||||||
|
Loading…
Reference in New Issue
Block a user