use core client with explicit version globally
Kubernetes-commit: 4c8539cece2f0a6e6974b30d00c7341e10320bc5
This commit is contained in:
parent
7001bc4df8
commit
41430fda7c
|
@ -165,7 +165,7 @@ func (l *lifecycle) Admit(a admission.Attributes) error {
|
|||
// refuse to operate on non-existent namespaces
|
||||
if !exists || forceLiveLookup {
|
||||
// as a last resort, make a call directly to storage
|
||||
namespace, err = l.client.Core().Namespaces().Get(a.GetNamespace(), metav1.GetOptions{})
|
||||
namespace, err = l.client.CoreV1().Namespaces().Get(a.GetNamespace(), metav1.GetOptions{})
|
||||
switch {
|
||||
case errors.IsNotFound(err):
|
||||
return err
|
||||
|
|
Loading…
Reference in New Issue