mirror of
				https://source.quilibrium.com/quilibrium/ceremonyclient.git
				synced 2025-11-04 00:07:52 +00:00 
			
		
		
		
	handle case where NAT traversing relay peer is not recognized by peer store
This commit is contained in:
		
							parent
							
								
									1a009e3769
								
							
						
					
					
						commit
						263ea5cba8
					
				@ -306,6 +306,11 @@ func (b *BlossomSub) GetNetworkPeersCount() int {
 | 
				
			|||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
func (b *BlossomSub) GetMultiaddrOfPeer(peerId []byte) string {
 | 
					func (b *BlossomSub) GetMultiaddrOfPeer(peerId []byte) string {
 | 
				
			||||||
 | 
						addrs := b.h.Peerstore().Addrs(peer.ID(peerId))
 | 
				
			||||||
 | 
						if len(addrs) == 0 {
 | 
				
			||||||
 | 
							return ""
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	return b.h.Peerstore().Addrs(peer.ID(peerId))[0].String()
 | 
						return b.h.Peerstore().Addrs(peer.ID(peerId))[0].String()
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user