diff --git a/internal/store/builder.go b/internal/store/builder.go index ff8deb78a1..c815d56f6f 100644 --- a/internal/store/builder.go +++ b/internal/store/builder.go @@ -538,8 +538,7 @@ func (b *Builder) buildStores( if b.fieldSelectorFilter != "" { klog.InfoS("FieldSelector is used", "fieldSelector", b.fieldSelectorFilter) } - kubeClient := b.kubeClient - listWatcher := listWatchFunc(kubeClient, v1.NamespaceAll, b.fieldSelectorFilter) + listWatcher := listWatchFunc(b.kubeClient, v1.NamespaceAll, b.fieldSelectorFilter) b.startReflector(expectedType, store, listWatcher, useAPIServerCache) return []cache.Store{store} }