未验证 提交 2bd32353 编写于 作者: C congqixia 提交者: GitHub

Fix zero length slice declaration in util/retry/retry.go (#12576)

Signed-off-by: NCongqi Xia <congqi.xia@zilliz.com>
上级 6dd7afd1
...@@ -28,7 +28,7 @@ func Do(ctx context.Context, fn func() error, opts ...Option) error { ...@@ -28,7 +28,7 @@ func Do(ctx context.Context, fn func() error, opts ...Option) error {
for _, opt := range opts { for _, opt := range opts {
opt(c) opt(c)
} }
el := make(ErrorList, 0) var el ErrorList
for i := uint(0); i < c.attempts; i++ { for i := uint(0); i < c.attempts; i++ {
if err := fn(); err != nil { if err := fn(); err != nil {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册