Skip to content

Commit

Permalink
chore: Cleanup linting
Browse files Browse the repository at this point in the history
  • Loading branch information
dariusc93 committed May 3, 2024
1 parent be913ff commit 44c5d0c
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 4 deletions.
1 change: 1 addition & 0 deletions packages/libp2p-relay-manager/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ impl PartialEq for Connection {

impl Eq for Connection {}

#[allow(dead_code)]
#[derive(Clone, Debug, PartialEq, Eq)]
struct PendingReservation {
peer_id: PeerId,
Expand Down
1 change: 0 additions & 1 deletion src/p2p/behaviour.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,6 @@ pub enum KadResult {
Peers(Vec<PeerId>),
/// The query successfully returns a `GetRecord` result.
Records(Vec<Record>),
///
Record(Record),
}

Expand Down
2 changes: 0 additions & 2 deletions src/repo/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1156,7 +1156,6 @@ impl RepoFetch {
self
}

///
pub fn exit_on_error(mut self) -> Self {
self.refs = self.refs.with_exit_on_error();
self
Expand Down Expand Up @@ -1287,7 +1286,6 @@ impl RepoInsertPin {
self
}

///
pub fn exit_on_error(mut self) -> Self {
self.refs = self.refs.with_exit_on_error();
self
Expand Down
2 changes: 1 addition & 1 deletion src/unixfs/ls.rs
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ impl Stream for UnixfsLs {
},
Ok(ContinuedWalk::RootDirectory( cid, path, _)) => {
let path = path.to_string_lossy().to_string();
root_directory = path.clone();
root_directory.clone_from(&path);
yield Entry::RootDirectory { cid: *cid, path };
}
Ok(ContinuedWalk::Directory( cid, path, _)) => {
Expand Down
1 change: 1 addition & 0 deletions unixfs/src/file.rs
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,7 @@ impl From<FileError> for FileReadFailed {
/// This at least sounded useful early on as the quick-protobuf produces many Option<Cow> values
/// which are a bit tricky to handle. We never turn them into Option<Cow::Owned> so we can safely
/// use these.
#[allow(dead_code)]
pub(crate) trait UnwrapBorrowedExt<'a> {
/// Does not default but requires there to be an borrowed inner value.
fn unwrap_borrowed(self) -> &'a [u8];
Expand Down

0 comments on commit 44c5d0c

Please sign in to comment.