Skip to content

Commit fef8968

Browse files
committed
Revert
1 parent 6c89aea commit fef8968

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

controllers/postgres_controller.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,6 @@ func (r *PostgresReconciler) Reconcile(ctx context.Context, req ctrl.Request) (c
7272
return ctrl.Result{}, nil
7373
}
7474

75-
namespace := instance.ToPeripheralResourceNamespace()
76-
7775
// Delete
7876
if instance.IsBeingDeleted() {
7977
instance.Status.Description = "Terminating"
@@ -84,6 +82,7 @@ func (r *PostgresReconciler) Reconcile(ctx context.Context, req ctrl.Request) (c
8482
log.Info("instance being deleted")
8583

8684
matchingLabels := instance.ToZalandoPostgresqlMatchingLabels()
85+
namespace := instance.ToPeripheralResourceNamespace()
8786

8887
if err := r.deleteCWNP(ctx, instance); client.IgnoreNotFound(err) != nil { // todo: remove ignorenotfound
8988
r.recorder.Event(instance, "Warning", "Error", "failed to delete ClusterwideNetworkPolicy")

0 commit comments

Comments
 (0)