diff --git a/internal/cmd/reload/reload.go b/internal/cmd/reload/reload.go index 160a5b3..2943072 100644 --- a/internal/cmd/reload/reload.go +++ b/internal/cmd/reload/reload.go @@ -128,7 +128,7 @@ func GetAnyValBy[T, A any](namespace string, tryTimes int, a A, fn func(A) (T, b } v.v, ok = fn(a) times := v.counter() - if ok || times == tryTimes { + if ok || times >= tryTimes { v.ok = true vv.Val.Store(v) }