mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-01 07:47:56 +00:00
Remove unreachable panic statement.
The availability zone always exist since it is retrieved from the instance's EC2 metadata service during cloud provider construction.
This commit is contained in:
parent
4407ca9a64
commit
5d5013a722
@ -744,10 +744,6 @@ func (aws *AWSCloud) List(filter string) ([]string, error) {
|
|||||||
|
|
||||||
// GetZone implements Zones.GetZone
|
// GetZone implements Zones.GetZone
|
||||||
func (self *AWSCloud) GetZone() (cloudprovider.Zone, error) {
|
func (self *AWSCloud) GetZone() (cloudprovider.Zone, error) {
|
||||||
if self.availabilityZone == "" {
|
|
||||||
// Should be unreachable
|
|
||||||
panic("availabilityZone not set")
|
|
||||||
}
|
|
||||||
return cloudprovider.Zone{
|
return cloudprovider.Zone{
|
||||||
FailureDomain: self.availabilityZone,
|
FailureDomain: self.availabilityZone,
|
||||||
Region: self.region,
|
Region: self.region,
|
||||||
|
Loading…
Reference in New Issue
Block a user