Skip to content
Snippets Groups Projects
Commit 1aa62495 authored by Georgy Moshkin's avatar Georgy Moshkin :speech_balloon: Committed by Georgy Moshkin
Browse files

refactor(storage): rename and fix storage::Peers::get

parent c68db882
No related branches found
No related tags found
1 merge request!244attempt at topology governor
......@@ -299,10 +299,7 @@ impl Peers {
/// (see `PeerFieldDef` & `peer_field` module).
#[inline(always)]
#[allow(dead_code)]
pub fn peer<F>(&self, id: &impl PeerId) -> Result<F::Type, TraftError>
where
F: PeerFieldDef,
{
pub fn get(&self, id: &impl PeerId) -> Result<traft::Peer, TraftError> {
let res = id.find_in(self)?.decode().expect("failed to decode peer");
Ok(res)
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment