Skip to content

Commit ced8008

Browse files
committed
chore(lint): fix rust lint errors
1 parent d885405 commit ced8008

4 files changed

Lines changed: 4 additions & 6 deletions

File tree

.github/workflows/CI.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,6 @@ jobs:
135135
id-token: write # required for trusted publishing
136136
needs:
137137
- lint
138-
- test-macOS-windows-binding
139-
- test-linux-binding
140138

141139
steps:
142140
- uses: actions/checkout@v6

build.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
fn main() {
2-
napi_build::setup();
2+
napi_build::setup();
33
}

src/connection.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ impl Connection {
8282
#[napi]
8383
pub async fn closed(&self) -> Result<String> {
8484
let err = self.inner.closed().await;
85-
Ok(format!("{}", err))
85+
Ok(format!("{err}"))
8686
}
8787

8888
/// Get the current round-trip time estimate in milliseconds

src/endpoint.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ impl Endpoint {
9696
// Parse the address as an EndpointId first (just the node ID)
9797
let endpoint_id: iroh::EndpointId = addr
9898
.parse()
99-
.map_err(|e| to_napi_error(format!("Invalid node ID: {}", e)))?;
99+
.map_err(|e| to_napi_error(format!("Invalid node ID: {e}")))?;
100100

101101
let conn = self
102102
.inner
@@ -143,7 +143,7 @@ fn hex_to_bytes(hex: &str) -> std::result::Result<Vec<u8>, String> {
143143
.step_by(2)
144144
.map(|i| {
145145
u8::from_str_radix(&hex[i..i + 2], 16)
146-
.map_err(|e| format!("Invalid hex at position {}: {}", i, e))
146+
.map_err(|e| format!("Invalid hex at position {i}: {e}"))
147147
})
148148
.collect()
149149
}

0 commit comments

Comments
 (0)