Fix deepsource findings (#7457)

* remove unused code

* Incomplete condition fix

* club append to single call

* anti-pattern fix 'should use for range instead of for { select {} }'

* use strings.ReplaceAll

* replace `len(parts[0]) == 0` with `parts[0] == ""`

Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
This commit is contained in:
Preston Van Loon
2020-10-08 01:36:47 -07:00
committed by GitHub
parent 390a589afb
commit d4e6ce6998
9 changed files with 19 additions and 79 deletions

View File

@@ -54,14 +54,11 @@ func main() {
ticker := time.NewTicker(time.Duration(params.BeaconConfig().SecondsPerSlot) * time.Second)
go func() {
for {
select {
case <-ticker.C:
if *compare {
compareHeads(clients)
} else {
displayHeads(clients)
}
for range ticker.C {
if *compare {
compareHeads(clients)
} else {
displayHeads(clients)
}
}
}()