don't join buckets if there is only one
This commit is contained in:
parent
c52541197f
commit
3868dea819
1 changed files with 2 additions and 0 deletions
|
@ -281,6 +281,8 @@ class TreeRoutingTable:
|
|||
old_bucket.remove_peer(contact)
|
||||
|
||||
def join_buckets(self):
|
||||
if len(self.buckets) == 1:
|
||||
return
|
||||
to_pop = [i for i, bucket in enumerate(self.buckets) if not len(bucket)]
|
||||
if not to_pop:
|
||||
return
|
||||
|
|
Loading…
Reference in a new issue