clarify friends.hops in the example

This commit is contained in:
glyph 2022-02-16 14:17:58 +02:00
parent 4281f40523
commit b0ac8e7a29
1 changed files with 5 additions and 2 deletions

View File

@ -51,10 +51,13 @@ async fn run() -> Result<(), GolgiError> {
// Blocking can be achieved in a similar fashion.
let _block_response = sbot_client.block(&to_block).await?;
// Get a list of peers within 1 hop of the local identity.
// Get a list of peers within 0 hops of the local identity.
// This returns a list of peers whom we follow.
// If `max` is set to 1, the list will include the peers we follow plus
// the peers that they follow.
let follows = sbot_client
.friends_hops(FriendsHops {
max: 1,
max: 0,
start: None,
// The `reverse` parameter is not currently implemented in `go-sbot`.
reverse: Some(false),