Fix namespace controller on delete to not care if item not found

This commit is contained in:
derekwaynecarr
2015-06-03 22:59:07 -04:00
parent bc0816f5e5
commit 14d2128238
3 changed files with 29 additions and 15 deletions

View File

@@ -102,7 +102,7 @@ func (r *REST) Delete(ctx api.Context, name string, options *api.DeleteOptions)
// prior to final deletion, we must ensure that finalizers is empty
if len(namespace.Spec.Finalizers) != 0 {
err = apierrors.NewConflict("Namespace", namespace.Name, fmt.Errorf("Termination is in progress, waiting for %v", namespace.Spec.Finalizers))
err = apierrors.NewConflict("Namespace", namespace.Name, fmt.Errorf("The system is ensuring all content is removed from this namespace. Upon completion, this namespace will automatically be purged by the system."))
return nil, err
}
return r.Etcd.Delete(ctx, name, nil)