mirror of
https://github.com/yusing/godoxy.git
synced 2026-03-31 14:13:09 +02:00
fix(pool): variable shadowing
This commit is contained in:
@@ -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 {
|
||||
|
||||
Reference in New Issue
Block a user