From 0c8ba12f807b5f2e09904dc4764fc16e3392fde5 Mon Sep 17 00:00:00 2001 From: Max Smythe Date: Wed, 26 Apr 2023 10:54:36 -0700 Subject: [PATCH] Fix lint error Signed-off-by: Max Smythe --- pkg/cache/informer_cache.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/cache/informer_cache.go b/pkg/cache/informer_cache.go index 2bbe178273..c2a19232c3 100644 --- a/pkg/cache/informer_cache.go +++ b/pkg/cache/informer_cache.go @@ -161,10 +161,10 @@ func (ic *informerCache) GetInformerNonBlocking(ctx context.Context, obj client. } // Use a canceled context to signal non-blocking - ctx, cancel := context.WithCancel(context.Background()) + canceledCtx, cancel := context.WithCancel(context.Background()) cancel() - _, i, err := ic.Informers.Get(ctx, gvk, obj) + _, i, err := ic.Informers.Get(canceledCtx, gvk, obj) if err != nil && !apierrors.IsTimeout(err) { return nil, err }