Skip to content

Commit 93f19ea

Browse files
committed
Fix condition
1 parent 27206fe commit 93f19ea

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

common/src/format.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -436,7 +436,7 @@ impl FormatSpec {
436436
let sep = char::from(fg);
437437
let inter = self.get_separator_interval().try_into().unwrap();
438438
let magnitude_len = magnitude_str.len();
439-
let disp_digit_cnt = if let Some('0') = self.fill.and_then(|p| p.to_char()) {
439+
let disp_digit_cnt = if self.fill == Some('0'.into()) {
440440
let width = self.width.unwrap_or(magnitude_len) as i32 - prefix.len() as i32;
441441
cmp::max(width, magnitude_len as i32)
442442
} else {

0 commit comments

Comments
 (0)