Skip to content

Commit

Permalink
fix: staticcheck error
Browse files Browse the repository at this point in the history
  • Loading branch information
dennis-tra committed Aug 12, 2022
1 parent 4a08bb9 commit d1faaa3
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions lookup_estim.go
Original file line number Diff line number Diff line change
Expand Up @@ -215,11 +215,7 @@ func (es *estimatorState) stopFn(qps *qpeerset.QueryPeerset) bool {
avg := sum / float64(len(distances))

// if the average is below the set threshold stop the procedure
if avg < es.setThreshold {
return true
}

return false
return avg < es.setThreshold
}

func (es *estimatorState) putProviderRecord(pid peer.ID) {
Expand Down

0 comments on commit d1faaa3

Please sign in to comment.