Skip to content

Commit

Permalink
Make clippy happy
Browse files Browse the repository at this point in the history
  • Loading branch information
mitsuhiko committed Jan 9, 2024
1 parent 3602744 commit b54f13d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/utils.rs
Expand Up @@ -778,8 +778,8 @@ pub fn truncate_str<'a>(s: &'a str, width: usize, tail: &str) -> Cow<'a, str> {
}
}
(s, true) => {
if rv.is_some() {
rv.as_mut().unwrap().push_str(s);
if let Some(ref mut rv) = rv {
rv.push_str(s);
}
}
}
Expand Down

0 comments on commit b54f13d

Please sign in to comment.