Merge pull request #703 from Arceliar/dht

Store less in the DHT
This commit is contained in:
Neil Alexander 2020-05-25 22:18:00 +01:00 committed by GitHub
commit 45810fa184
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -260,7 +260,9 @@ func (t *dht) handleRes(res *dhtRes) {
key: res.Key, key: res.Key,
coords: res.Coords, coords: res.Coords,
} }
if t.isImportant(&rinfo) {
t.insert(&rinfo) t.insert(&rinfo)
}
for _, info := range res.Infos { for _, info := range res.Infos {
if *info.getNodeID() == t.nodeID { if *info.getNodeID() == t.nodeID {
continue continue