Closing the last remaining PeerDiscoverySession for a topic will currently not delete the PeerDiscovery object from the swarm._discoveryMap. If PeerDiscovery.destroy is always called through Hyperswarm.leave, then all discovery objects will be fully GC'd on leave.
Closing the last remaining
PeerDiscoverySession
for a topic will currently not delete thePeerDiscovery
object from theswarm._discovery
Map
. IfPeerDiscovery.destroy
is always called throughHyperswarm.leave
, then all discovery objects will be fully GC'd on leave.