Move code to switch default.

This commit is contained in:
Mariano Cano 2019-04-24 14:50:22 -07:00
parent a7f06c765d
commit b6a5ebcfc9

View file

@ -100,10 +100,11 @@ func (c *Collection) LoadByCertificate(cert *x509.Certificate) (Interface, bool)
return c.Load("aws:" + string(provisioner.Name))
case TypeGCP:
return c.Load("gcp:" + string(provisioner.Name))
}
default:
return c.Load(string(provisioner.CredentialID))
}
}
}
// Default to noop provisioner if an extension is not found. This allows to
// accept a renewal of a cert without the provisioner extension.