Fix issues reported by semgrep

This commit is contained in:
Alexander Neumann 2020-12-11 09:41:59 +01:00
parent 7facc8ccc1
commit 36c5d39c2c
5 changed files with 6 additions and 26 deletions

View file

@ -42,7 +42,7 @@ func retry(max int, fail func(err error), f func() error) error {
for i := 0; i < max; i++ {
err = f()
if err == nil {
return err
return nil
}
if fail != nil {
fail(err)