Commit 9ff43d6e authored by Steven Allen's avatar Steven Allen

note that the peerstore attempts to extract the key from the peer id

parent 26ed97fd
......@@ -26,7 +26,8 @@ type pubkrs struct {
func (dht *IpfsDHT) GetPublicKey(ctx context.Context, p peer.ID) (ci.PubKey, error) {
log.Debugf("getPublicKey for: %s", p)
// check locally.
// Check locally. Will also try to extract the public key from the peer
// ID itself if possible (if inlined).
pk := dht.peerstore.PubKey(p)
if pk != nil {
return pk, nil
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment