mirror of
https://github.com/rutgersc/m3u8-rs.git
synced 2024-12-23 06:56:29 +00:00
Fix clippy warning
warning: useless conversion to the same type: `std::string::String` --> src/playlist.rs:415:77 | 415 | QuotedOrUnquoted::Unquoted(s) => Ok(ClosedCaptionGroupId::Other(String::from(s))), | ^^^^^^^^^^^^^^^ help: consider removing `String::from()`: `s` | = note: `#[warn(clippy::useless_conversion)]` on by default = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
This commit is contained in:
parent
14d24b94c8
commit
f9b5420c0a
1 changed files with 1 additions and 1 deletions
|
@ -412,7 +412,7 @@ impl TryFrom<QuotedOrUnquoted> for ClosedCaptionGroupId {
|
||||||
fn try_from(s: QuotedOrUnquoted) -> Result<ClosedCaptionGroupId, String> {
|
fn try_from(s: QuotedOrUnquoted) -> Result<ClosedCaptionGroupId, String> {
|
||||||
match s {
|
match s {
|
||||||
QuotedOrUnquoted::Unquoted(s) if s == "NONE" => Ok(ClosedCaptionGroupId::None),
|
QuotedOrUnquoted::Unquoted(s) if s == "NONE" => Ok(ClosedCaptionGroupId::None),
|
||||||
QuotedOrUnquoted::Unquoted(s) => Ok(ClosedCaptionGroupId::Other(String::from(s))),
|
QuotedOrUnquoted::Unquoted(s) => Ok(ClosedCaptionGroupId::Other(s)),
|
||||||
QuotedOrUnquoted::Quoted(s) => Ok(ClosedCaptionGroupId::GroupId(s)),
|
QuotedOrUnquoted::Quoted(s) => Ok(ClosedCaptionGroupId::GroupId(s)),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue