mirror of
https://github.com/Serial-ATA/lofty-rs
synced 2024-11-14 00:17:07 +00:00
Remove unnecessary clone
This commit is contained in:
parent
d86e007fe7
commit
e58355af74
1 changed files with 6 additions and 5 deletions
|
@ -239,20 +239,21 @@ impl From<Tag> for VorbisComments {
|
|||
}
|
||||
|
||||
for item in input.items {
|
||||
let item_key = item.item_key;
|
||||
let item_value = item.item_value;
|
||||
|
||||
// Discard binary items, as they are not allowed in Vorbis comments
|
||||
let val = match item.value() {
|
||||
let val = match item_value {
|
||||
ItemValue::Text(text) | ItemValue::Locator(text) => text,
|
||||
_ => continue,
|
||||
};
|
||||
|
||||
let key = match item.key().map_key(TagType::VorbisComments, true) {
|
||||
let key = match item_key.map_key(TagType::VorbisComments, true) {
|
||||
None => continue,
|
||||
Some(k) => k,
|
||||
};
|
||||
|
||||
vorbis_comments
|
||||
.items
|
||||
.push((key.to_string(), val.to_string()));
|
||||
vorbis_comments.items.push((key.to_string(), val));
|
||||
}
|
||||
|
||||
for picture in input.pictures {
|
||||
|
|
Loading…
Reference in a new issue