Skip to content

Commit 2b6d27d

Browse files
committed
misc: Apply clippy lints
1 parent 89cfd34 commit 2b6d27d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/colorize.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,14 +118,15 @@ pub fn colorize_to_array(diff: &Value) -> Vec<String> {
118118
///
119119
/// If `None`, there is no JSON structural difference to be formatted.
120120
#[cfg(feature = "colorize")]
121+
#[must_use]
121122
#[allow(clippy::module_name_repetitions)]
122123
pub fn colorize(diff: &Value, is_color: bool) -> String {
123124
use console::Style;
124125

125126
let mut output: Vec<String> = Vec::new();
126127

127128
let mut output_func = |color: &str, line: &str| {
128-
let color_line = format!("{}{}", color, line);
129+
let color_line = format!("{color}{line}");
129130
let str_output = if is_color {
130131
match color {
131132
"+" => format!("{}", Style::new().green().apply_to(color_line)),

0 commit comments

Comments
 (0)