async fn add_or_update_node(&self, node: &Node) {
        let existing_node = self.get_known_nodes(&node.id).await;
        if let Some(node) = existing_node {
            self.update_node(node).await;
        } else {
            self.add_node(node).await;
        }
    }
/// Add or update a node (depending on whether the registry it's already in
/// the registry or not)
Add or update a node (depending on whether the registry it's already in
the registry or not)
Add or update a node ( depending on whether the registry it ' s already in the registry or not )
async fn add_or_update_node(&self, node: &Node) {
        let existing_node = self.get_known_nodes(&node.id).await;
        if let Some(node) = existing_node {
            self.update_node(node).await;
        } else {
            self.add_node(node).await;
        }
    }
async fn add_or_update_node ( & self , node : & Node ) { let existing_node = self . get_known_nodes ( & node . id ) . await ; if let Some ( node ) = existing_node { self . update_node ( node ) . await ; } else { self . add_node ( node ) . await ; } }
Add or update a node (depending on whether the registry it's already in
the registry or not)
Add or update a node ( depending on whether the registry it ' s already in the registry or not )
&self
node
&Node