Skip to content

Commit c937275

Browse files
committed
fix: replace flatten() with map_while(Result::ok) to fix clippy warning
1 parent b602c10 commit c937275

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ fn run_with_throttle(delay_ms: u64) -> Result<()> {
7373
let reader = BufReader::new(stdout);
7474
let mut out = std::io::stdout().lock();
7575

76-
for line in reader.lines().flatten() {
76+
for line in reader.lines().map_while(Result::ok) {
7777
let _ = writeln!(out, "{}", line);
7878
let _ = out.flush();
7979
std::thread::sleep(delay);

0 commit comments

Comments
 (0)