From c89c737ecda0d44b6022c0095e1b9848916c8916 Mon Sep 17 00:00:00 2001 From: yusing Date: Fri, 10 Oct 2025 10:01:42 +0800 Subject: [PATCH] fix(pool): variable shadowing --- internal/utils/pool/pool.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/utils/pool/pool.go b/internal/utils/pool/pool.go index 2e086461..aad6ce81 100644 --- a/internal/utils/pool/pool.go +++ b/internal/utils/pool/pool.go @@ -98,8 +98,8 @@ func (p *Pool[T]) logAction(action string, obj T) { if p.disableLog.Load() { return } - if obj, ok := any(obj).(ObjectWithDisplayName); ok { - disp, name := obj.DisplayName(), obj.Name() + if withName, ok := any(obj).(ObjectWithDisplayName); ok { + disp, name := withName.DisplayName(), withName.Name() if disp != name { log.Info().Msgf("%s: %s %s (%s)", p.name, action, disp, name) } else {