mirror of
https://github.com/libp2p/go-libp2p-core.git
synced 2025-03-23 12:30:08 +08:00
13 lines
348 B
Go
13 lines
348 B
Go
package host
|
|
|
|
import (
|
|
"github.com/libp2p/go-libp2p/core/host"
|
|
"github.com/libp2p/go-libp2p/core/peer"
|
|
)
|
|
|
|
// InfoFromHost returns a peer.AddrInfo struct with the Host's ID and all of its Addrs.
|
|
// Deprecated: use github.com/libp2p/go-libp2p/core/host.InfoFromHost instead
|
|
func InfoFromHost(h Host) *peer.AddrInfo {
|
|
return host.InfoFromHost(h)
|
|
}
|