mirror of
https://github.com/logos-storage/logos-storage-nim-dht.git
synced 2026-08-03 13:13:22 +00:00
Call random2 shuffle
This commit is contained in:
parent
1bb5236e26
commit
8cd70ad71f
@ -555,7 +555,7 @@ proc nodeToRevalidate*(r: RoutingTable): Node =
|
||||
## Return a node to revalidate. The least recently seen node from a random
|
||||
## bucket is selected.
|
||||
var buckets = r.buckets
|
||||
r.rng.shuffle(buckets)
|
||||
random2.shuffle(r.rng, buckets)
|
||||
# TODO: Should we prioritize less-recently-updated buckets instead? Could
|
||||
# store a `now` Moment at setJustSeen or at revalidate per bucket.
|
||||
for b in buckets:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user