DeleteHooks: Fix logging (#112033)
This commit is contained in:
@@ -651,7 +651,7 @@ func (b *DashboardsAPIBuilder) afterDelete(obj runtime.Object, _ *metav1.DeleteO
|
||||
client := (*b.resourcePermissionsSvc).Namespace(meta.GetNamespace())
|
||||
name := fmt.Sprintf("%s-%s-%s", dashv1.DashboardResourceInfo.GroupVersionResource().Group, dashv1.DashboardResourceInfo.GroupVersionResource().Resource, meta.GetName())
|
||||
err = client.Delete(ctx, name, metav1.DeleteOptions{})
|
||||
if err != nil {
|
||||
if err != nil && !apierrors.IsNotFound(err) {
|
||||
log.Error("failed to delete dashboard permissions", "error", err)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user