Skip to content

Commit a44aa36

Browse files
committed
refactor: improve code style
1 parent f692b91 commit a44aa36

1 file changed

Lines changed: 3 additions & 8 deletions

File tree

src/reporter/progress_report.rs

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -21,17 +21,12 @@ impl<Size: size::Size + Into<u64>> ProgressReport<Size> {
2121
errors,
2222
} = report;
2323
let mut text = String::new();
24-
write!(
25-
text,
26-
"\r(scanned {items}, total {total}",
27-
items = items,
28-
total = total.into(),
29-
)
30-
.unwrap();
24+
let total: u64 = total.into();
25+
write!(text, "\r(scanned {items}, total {total}").unwrap();
3126
if errors != 0 {
3227
write!(text, ", erred {errors}").unwrap();
3328
}
34-
write!(text, ")").unwrap();
29+
text.push(')');
3530
GLOBAL_STATUS_BOARD.temporary_message(&text);
3631
};
3732
}

0 commit comments

Comments
 (0)