Remove redundant condition
This commit is contained in:
parent
3ac71fc58d
commit
9d194eb6f5
|
@ -31,11 +31,9 @@ func (s RandomSampler) Sample(lvl Level) bool {
|
||||||
if s <= 0 {
|
if s <= 0 {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
if s > 0 {
|
|
||||||
if rand.Intn(int(s)) != 0 {
|
if rand.Intn(int(s)) != 0 {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
}
|
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue