RCT: fix retry
This commit is contained in:
parent
c21d1a83fb
commit
db3f355ab6
1 changed files with 2 additions and 1 deletions
|
|
@ -174,9 +174,10 @@ func (m *RCT) queryFloat(id rct.Identifier) (float64, error) {
|
|||
|
||||
res, err := backoff.RetryWithData(func() (float32, error) {
|
||||
res, err := m.conn.QueryFloat32(id)
|
||||
if !errors.Is(err, rct.RecoverableError{}) {
|
||||
if err != nil && !errors.As(err, new(rct.RecoverableError)) {
|
||||
err = backoff.Permanent(err)
|
||||
}
|
||||
|
||||
return res, err
|
||||
}, m.bo)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue