Merge pull request #97650 from ialidzhikov/cleanup/redundant-imports
Clean up some redundant imports
This commit is contained in:
@@ -29,7 +29,6 @@ import (
|
||||
apps "k8s.io/api/apps/v1"
|
||||
v1 "k8s.io/api/core/v1"
|
||||
apiequality "k8s.io/apimachinery/pkg/api/equality"
|
||||
"k8s.io/apimachinery/pkg/api/errors"
|
||||
apierrors "k8s.io/apimachinery/pkg/api/errors"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
"k8s.io/apimachinery/pkg/labels"
|
||||
@@ -1001,7 +1000,7 @@ func (dsc *DaemonSetsController) syncNodes(ds *apps.DaemonSet, podsToDelete, nod
|
||||
ds, metav1.NewControllerRef(ds, controllerKind))
|
||||
|
||||
if err != nil {
|
||||
if errors.HasStatusCause(err, v1.NamespaceTerminatingCause) {
|
||||
if apierrors.HasStatusCause(err, v1.NamespaceTerminatingCause) {
|
||||
// If the namespace is being torn down, we can safely ignore
|
||||
// this error since all subsequent creations will fail.
|
||||
return
|
||||
@@ -1164,7 +1163,7 @@ func (dsc *DaemonSetsController) syncDaemonSet(key string) error {
|
||||
return err
|
||||
}
|
||||
ds, err := dsc.dsLister.DaemonSets(namespace).Get(name)
|
||||
if errors.IsNotFound(err) {
|
||||
if apierrors.IsNotFound(err) {
|
||||
klog.V(3).Infof("daemon set has been deleted %v", key)
|
||||
dsc.expectations.DeleteExpectations(key)
|
||||
return nil
|
||||
|
Reference in New Issue
Block a user