mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-14 05:36:12 +00:00
Guard against non AWS errors.
This commit is contained in:
@@ -1295,7 +1295,7 @@ func (s *AWSCloud) describeLoadBalancer(region, name string) (*elb.LoadBalancerD
|
||||
|
||||
response, err := elbClient.DescribeLoadBalancers(request)
|
||||
if err != nil {
|
||||
if awsError := err.(awserr.Error); awsError != nil {
|
||||
if awsError, ok := err.(awserr.Error); ok {
|
||||
if awsError.Code() == "LoadBalancerNotFound" {
|
||||
return nil, nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user