From 4beba762f4b6f79d5b82f935525e29b7bae20267 Mon Sep 17 00:00:00 2001 From: Guilherme Cassolato Date: Mon, 30 Sep 2024 16:14:14 +0200 Subject: [PATCH] controller: delete resource from recent list Signed-off-by: Guilherme Cassolato --- controller/controller.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/controller/controller.go b/controller/controller.go index bf966e0..13f112b 100644 --- a/controller/controller.go +++ b/controller/controller.go @@ -301,6 +301,9 @@ func (c *Controller) subscribe(ctx context.Context) { OldObject: oldObj, } _, exists := newObjs[uid] + if !exists { + delete(oldObjs, uid) + } return event, !exists })