Commit 76f388b6 authored by Steven Allen's avatar Steven Allen

chore(bootstrap): reduce indent level

parent 4eaf4293
......@@ -102,7 +102,9 @@ func (dht *IpfsDHT) refreshBuckets(ctx context.Context) {
buckets = buckets[:16]
}
for bucketID, bucket := range buckets {
if time.Since(bucket.RefreshedAt()) > dht.rtRefreshPeriod {
if time.Since(bucket.RefreshedAt()) <= dht.rtRefreshPeriod {
continue
}
// gen rand peer in the bucket
randPeerInBucket := dht.routingTable.GenRandPeerID(bucketID)
......@@ -119,7 +121,6 @@ func (dht *IpfsDHT) refreshBuckets(ctx context.Context) {
logger.Warningf("failed to do a random walk on bucket %d", bucketID)
}
}
}
}
// Traverse the DHT toward the self ID
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment