diff --git a/pkg/varlog/operations.go b/pkg/varlog/operations.go index 5e41f939a..1d7495417 100644 --- a/pkg/varlog/operations.go +++ b/pkg/varlog/operations.go @@ -74,7 +74,7 @@ RETRY: for idx := 0; idx < len(res); idx++ { if len(res[idx].Error) > 0 { - if strings.Contains(err.Error(), "sealed") { + if strings.Contains(res[idx].Error, "sealed") { result.Err = fmt.Errorf("append: %s: %w", res[idx].Error, verrors.ErrSealed) } else { result.Err = fmt.Errorf("append: %s", res[idx].Error)