mirror of
https://github.com/ipfs/kubo.git
synced 2025-06-29 01:12:24 +08:00
peer.DecodePrettyID
This commit is contained in:

committed by
Brian Tiger Chow

parent
d040104762
commit
569268c676
@ -26,6 +26,11 @@ func (id ID) Pretty() string {
|
|||||||
return b58.Encode(id)
|
return b58.Encode(id)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// DecodePrettyID returns a b58-encoded string of the ID
|
||||||
|
func DecodePrettyID(s string) ID {
|
||||||
|
return b58.Decode(s)
|
||||||
|
}
|
||||||
|
|
||||||
// Map maps Key (string) : *Peer (slices are not comparable).
|
// Map maps Key (string) : *Peer (slices are not comparable).
|
||||||
type Map map[u.Key]*Peer
|
type Map map[u.Key]*Peer
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user