Skip to content
This repository has been archived by the owner on Aug 19, 2022. It is now read-only.

Commit

Permalink
remove removal that is not required
Browse files Browse the repository at this point in the history
  • Loading branch information
aarshkshah1992 committed Apr 1, 2020
1 parent 416a1c1 commit fa55f77
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions pstoremem/addr_book.go
Original file line number Diff line number Diff line change
Expand Up @@ -277,11 +277,6 @@ func (mab *memoryAddrBook) SetAddrs(p peer.ID, addrs []ma.Multiaddr, ttl time.Du
delete(amap, key)
}
}

// if we've expired all the signed addresses for a peer, remove their signed routing state record
if len(amap) == 0 {
delete(s.signedPeerRecords, p)
}
}

// UpdateAddrs updates the addresses associated with the given peer that have
Expand All @@ -301,11 +296,6 @@ func (mab *memoryAddrBook) UpdateAddrs(p peer.ID, oldTTL time.Duration, newTTL t
}
}
}

// if we've expired all the signed addresses for a peer, remove their signed routing state record
if len(amap) == 0 {
delete(s.signedPeerRecords, p)
}
}

// Addrs returns all known (and valid) addresses for a given peer
Expand Down

0 comments on commit fa55f77

Please sign in to comment.