diff options
author | Alex Auvolat <alex@adnab.me> | 2020-12-12 21:14:15 +0100 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2020-12-12 21:14:15 +0100 |
commit | 6742638c81f8bda2ba3e3ab72ec520ab22b314e2 (patch) | |
tree | 0e85579ed8523a4fc8448d931a302350cbf9e952 /examples/fullmesh.rs | |
parent | 50401989724ed70f031055463e21caad76589742 (diff) | |
download | netapp-6742638c81f8bda2ba3e3ab72ec520ab22b314e2.tar.gz netapp-6742638c81f8bda2ba3e3ab72ec520ab22b314e2.zip |
Replace pk,pubkey,PublicKey by id,NodeID,etc
Diffstat (limited to 'examples/fullmesh.rs')
-rw-r--r-- | examples/fullmesh.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/fullmesh.rs b/examples/fullmesh.rs index eb954b7..acc0a7b 100644 --- a/examples/fullmesh.rs +++ b/examples/fullmesh.rs @@ -10,6 +10,7 @@ use sodiumoxide::crypto::sign::ed25519; use netapp::peering::fullmesh::*; use netapp::NetApp; +use netapp::NodeID; #[derive(StructOpt, Debug)] #[structopt(name = "netapp")] @@ -71,7 +72,7 @@ async fn main() { for peer in opt.bootstrap_peers.iter() { if let Some(delim) = peer.find('@') { let (key, ip) = peer.split_at(delim); - let pubkey = ed25519::PublicKey::from_slice(&hex::decode(&key).unwrap()).unwrap(); + let pubkey = NodeID::from_slice(&hex::decode(&key).unwrap()).unwrap(); let ip = ip[1..].parse::<SocketAddr>().unwrap(); bootstrap_peers.push((pubkey, ip)); } |