Merge pull request #45 from mhchia/fix/doc-client-getclosestpeers

Fix the docstring of `Client.GetClosestPeers`
This commit is contained in:
vyzo 2018-12-08 19:29:47 +02:00 committed by GitHub
commit c1b91e7b3f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -336,8 +336,8 @@ func (c *Client) FindProviders(ctx context.Context, cid cid.Cid) (<-chan PeerInf
return c.streamRequestPeerInfo(ctx, req)
}
// GetClosestPeers queries the DHT for peers that provide a piece of content
// identified by a CID.
// GetClosestPeers queries the DHT routing table for peers that are closest
// to a provided key.
func (c *Client) GetClosestPeers(ctx context.Context, key string) (<-chan peer.ID, error) {
req := newDHTReq(&pb.DHTRequest{
Type: pb.DHTRequest_GET_CLOSEST_PEERS.Enum(),