Skip to content

Commit

Permalink
chore: clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
drewstone committed Dec 10, 2024
1 parent f44bfd6 commit 67e8c5e
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions blueprint-test-utils/src/tangle/node.rs
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ impl SubstrateNodeBuilder {
// Spawn thread to handle stderr
let stderr_handle = thread::spawn(move || {
let reader = BufReader::new(stderr);
for line in reader.lines().flatten() {
for line in reader.lines().map_while(Result::ok) {
log::debug!(target: "node-stderr", "{}", line);
let _ = init_tx_clone.send(line.clone());
let _ = log_tx_clone.send(line);
Expand All @@ -155,7 +155,7 @@ impl SubstrateNodeBuilder {
// Spawn thread to handle stdout
let stdout_handle = thread::spawn(move || {
let reader = BufReader::new(stdout);
for line in reader.lines().flatten() {
for line in reader.lines().map_while(Result::ok) {
log::debug!(target: "node-stdout", "{}", line);
let _ = log_tx_stdout.send(line);
}
Expand Down Expand Up @@ -277,7 +277,7 @@ impl SubstrateNode {
let log_tx_clone = log_tx.clone();
let handle = thread::spawn(move || {
let reader = BufReader::new(stdout);
for line in reader.lines().flatten() {
for line in reader.lines().map_while(Result::ok) {
log::debug!(target: "node-stdout", "{}", line);
let _ = log_tx_clone.send(line);
}
Expand All @@ -290,7 +290,7 @@ impl SubstrateNode {
let log_tx_clone = log_tx.clone();
let handle = thread::spawn(move || {
let reader = BufReader::new(stderr);
for line in reader.lines().flatten() {
for line in reader.lines().map_while(Result::ok) {
log::debug!(target: "node-stderr", "{}", line);
let _ = log_tx_clone.send(line);
}
Expand Down Expand Up @@ -333,7 +333,7 @@ impl SubstrateNode {
let log_tx = self.log_capture_tx.clone();
let handle = thread::spawn(move || {
let reader = BufReader::new(stdout);
for line in reader.lines().flatten() {
for line in reader.lines().map_while(Result::ok) {
log::debug!(target: "node-stdout", "{}", line);
if let Some(tx) = &log_tx {
let _ = tx.send(line);
Expand All @@ -347,7 +347,7 @@ impl SubstrateNode {
let log_tx = self.log_capture_tx.clone();
let handle = thread::spawn(move || {
let reader = BufReader::new(stderr);
for line in reader.lines().flatten() {
for line in reader.lines().map_while(Result::ok) {
log::debug!(target: "node-stderr", "{}", line);
if let Some(tx) = &log_tx {
let _ = tx.send(line);
Expand Down

0 comments on commit 67e8c5e

Please sign in to comment.