updated same_home_as to work for variable number of addresses
This commit is contained in:
parent
3fa6a165b3
commit
dbe3fcbf5a
|
@ -29,8 +29,7 @@ class KadPeerInfo(PeerInfo):
|
||||||
|
|
||||||
|
|
||||||
def same_home_as(self, node):
|
def same_home_as(self, node):
|
||||||
#TODO: handle more than one addr
|
return sorted(self.addrs) == sorted(node.addrs)
|
||||||
return self.addrs[0] == node.addrs[0]
|
|
||||||
|
|
||||||
def distance_to(self, node):
|
def distance_to(self, node):
|
||||||
"""
|
"""
|
||||||
|
|
Loading…
Reference in New Issue
Block a user