Fix a bug in cascading deletion of federation objects

This commit is contained in:
shashidharatd
2016-12-31 00:50:27 +05:30
parent ef44fa1919
commit 526590007c

View File

@@ -126,11 +126,11 @@ func (dh *DeletionHelper) HandleObjectInUnderlyingClusters(obj runtime.Object) (
// If the obj has FinalizerOrphan finalizer, then we need to orphan the // If the obj has FinalizerOrphan finalizer, then we need to orphan the
// corresponding objects in underlying clusters. // corresponding objects in underlying clusters.
// Just remove both the finalizers in that case. // Just remove both the finalizers in that case.
obj, err := dh.removeFinalizerFunc(obj, api_v1.FinalizerOrphan) obj, err := dh.removeFinalizerFunc(obj, FinalizerDeleteFromUnderlyingClusters)
if err != nil { if err != nil {
return obj, err return obj, err
} }
return dh.removeFinalizerFunc(obj, FinalizerDeleteFromUnderlyingClusters) return dh.removeFinalizerFunc(obj, api_v1.FinalizerOrphan)
} }
glog.V(2).Infof("Deleting obj %s from underlying clusters", objName) glog.V(2).Infof("Deleting obj %s from underlying clusters", objName)