Skip to content

Commit

Permalink
fix: lint issue
Browse files Browse the repository at this point in the history
  • Loading branch information
sunng87 committed Jun 14, 2024
1 parent 21772db commit 5efb0b6
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/support.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,7 @@ pub mod str {
}

pub fn into_string(self) -> String {
if let Ok(s) = String::from_utf8(self.buf) {
s
} else {
String::new()
}
String::from_utf8(self.buf).unwrap_or_default()
}
}

Expand Down

0 comments on commit 5efb0b6

Please sign in to comment.