code: func (ps *peerSet) notify(n peerSetNotify) {
  	ps.lock.Lock()
  	ps.notifyList = append(ps.notifyList, n)
  	peers := make([]*peer, 0, len(ps.peers))
  	for _, p := range ps.peers {
  		peers = append(peers, p)
  	}
  	ps.lock.Unlock()
  
  	for _, p := range peers {
  		n.registerPeer(p)
  	}
  }
docs: // notify adds a service to be notified about added or removed peers