revert friends example code
This commit is contained in:
parent
821198a400
commit
e16f567c19
|
@ -1,6 +1,10 @@
|
|||
use std::process;
|
||||
|
||||
use golgi::{sbot::Keystore, GolgiError, Sbot};
|
||||
use golgi::{
|
||||
api::friends::{FriendsHops, RelationshipQuery},
|
||||
sbot::Keystore,
|
||||
GolgiError, Sbot,
|
||||
};
|
||||
|
||||
// Golgi is an asynchronous library so we must call it from within an
|
||||
// async function. The `GolgiError` type encapsulates all possible
|
||||
|
@ -9,17 +13,7 @@ async fn run() -> Result<(), GolgiError> {
|
|||
// Attempt to initialise a connection to an sbot instance using the
|
||||
// secret file at the Patchwork path and the default IP address, port
|
||||
// and network key (aka. capabilities key).
|
||||
let mut sbot_client =
|
||||
Sbot::init(Keystore::GoSbot, Some("127.0.0.1:8021".to_string()), None).await?;
|
||||
// Sbot::init(Keystore::Patchwork, None, None).await?;
|
||||
|
||||
//let ssb_id = String::from("@PEqxT8YRvrkf2fyjAgTl8pmdo8aR4KVsKLyh0b5JyOE=.ed25519");
|
||||
let ssb_id = String::from("@HEqy940T6uB+T+d9Jaa58aNfRzLx9eRWqkZljBmnkmk=.ed25519");
|
||||
|
||||
let name = sbot_client.get_name(&ssb_id).await?;
|
||||
|
||||
println!("name: {}", name);
|
||||
/*
|
||||
let mut sbot_client = Sbot::init(Keystore::Patchwork, None, None).await?;
|
||||
|
||||
// Call the `whoami` RPC method to retrieve the public key for the sbot
|
||||
// identity. This is our 'local' public key.
|
||||
|
@ -120,8 +114,6 @@ async fn run() -> Result<(), GolgiError> {
|
|||
// Output should be `false`.
|
||||
println!("isfollowingmref(should be false): {}", mref);
|
||||
|
||||
*/
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue