Skip to content

Commit

Permalink
Take care of clippy hint
Browse files Browse the repository at this point in the history
  • Loading branch information
noeddl committed May 7, 2024
1 parent aa797b0 commit f94b927
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/chord_chart.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
use std::cmp::max;
use std::fmt;
use std::fmt::Write;

use crate::{FretID, Semitones, UkeString, Voicing, MIN_CHART_WIDTH};

Expand Down Expand Up @@ -76,8 +77,10 @@ impl ChordChart {
"-".to_string()
}
})
.map(|c| format!("-{}-|", c))
.collect();
.fold(String::new(), |mut output, c| {
let _ = write!(output, "-{c}-|");
output
});

format!("{} {}{}{}- {}\n", root_str, sym, nut, s, note)
}
Expand Down

0 comments on commit f94b927

Please sign in to comment.