db/upnp, playlist/pls: use AddItem(std::string_view)
This commit is contained in:
parent
44beae519d
commit
2f4e2935a3
|
@ -172,7 +172,7 @@ protected:
|
|||
if (tag_type != TAG_NUM_OF_ITEM_TYPES) {
|
||||
assert(object.type != UPnPDirObject::Type::UNKNOWN);
|
||||
|
||||
tag.AddItem(tag_type, value.c_str());
|
||||
tag.AddItem(tag_type, value);
|
||||
|
||||
if (tag_type == TAG_TITLE)
|
||||
object.name = TitleToPathSegment(std::move(value));
|
||||
|
|
|
@ -113,7 +113,7 @@ ParsePls(TextInputStream &is, std::forward_list<DetachedSong> &songs)
|
|||
|
||||
TagBuilder tag;
|
||||
if (!entry.title.empty())
|
||||
tag.AddItem(TAG_TITLE, entry.title.c_str());
|
||||
tag.AddItem(TAG_TITLE, entry.title);
|
||||
|
||||
if (entry.length > 0)
|
||||
tag.SetDuration(SignedSongTime::FromS(entry.length));
|
||||
|
|
|
@ -210,7 +210,7 @@ SoundCloudJsonData::EndMap() noexcept
|
|||
TagBuilder tag;
|
||||
tag.SetDuration(SignedSongTime::FromMS(duration));
|
||||
if (!title.empty())
|
||||
tag.AddItem(TAG_NAME, title.c_str());
|
||||
tag.AddItem(TAG_NAME, title);
|
||||
|
||||
songs.emplace_front(u.c_str(), tag.Commit());
|
||||
|
||||
|
|
Loading…
Reference in New Issue