Skip to content
This repository has been archived by the owner on Jun 25, 2021. It is now read-only.

Commit

Permalink
fix: remove use of wildcard match and unimplemented macro
Browse files Browse the repository at this point in the history
  • Loading branch information
oetyng committed Feb 23, 2021
1 parent 1354469 commit 84c53d8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions examples/stress.rs
Original file line number Diff line number Diff line change
Expand Up @@ -352,10 +352,9 @@ impl Network {
let dst = match dst {
DstLocation::Section(name) => name,
DstLocation::Node(name) => name,
DstLocation::Direct => {
DstLocation::Direct | DstLocation::EndUser(_) => {
return Err(format_err!("unexpected probe message dst: {:?}", dst))
}
_ => unimplemented!(),
};

self.probe_tracker.receive(&dst, message.proof_share);
Expand Down
4 changes: 2 additions & 2 deletions src/routing/approved.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ use std::{
cmp,
collections::{btree_map::Entry, BTreeMap},
net::SocketAddr,
slice, unimplemented,
slice,
};
use tokio::sync::mpsc;
use xor_name::{Prefix, XorName};
Expand Down Expand Up @@ -855,7 +855,7 @@ impl Approved {
let src_name = match src {
SrcLocation::Node(name) => name,
SrcLocation::Section(prefix) => prefix.name(),
_ => unimplemented!(),
SrcLocation::EndUser(_) => return Err(Error::InvalidSrcLocation),
};

let bounce_dst_key = *self.section_key_by_name(&src_name);
Expand Down

0 comments on commit 84c53d8

Please sign in to comment.