Update MediaBrowser.Model/Entities/MediaStream.cs
Co-authored-by: Cody Robibero <cody@robibe.ro>
This commit is contained in:
parent
3b21abd879
commit
f5a3408c89
|
@ -223,12 +223,17 @@ namespace MediaBrowser.Model.Entities
|
||||||
|
|
||||||
if (!string.IsNullOrEmpty(Title))
|
if (!string.IsNullOrEmpty(Title))
|
||||||
{
|
{
|
||||||
return attributes.AsEnumerable()
|
var result = new StringBuilder(Title);
|
||||||
// keep Tags that are not already in Title
|
foreach (var tag in attributes)
|
||||||
.Where(tag => Title.IndexOf(tag, StringComparison.OrdinalIgnoreCase) == -1)
|
{
|
||||||
// attributes concatenation, starting with Title
|
// Keep Tags that are not already in Title.
|
||||||
.Aggregate(new StringBuilder(Title), (builder, attr) => builder.Append(" - ").Append(attr))
|
if (Title.IndexOf(tag, StringComparison.OrdinalIgnoreCase) == -1)
|
||||||
.ToString();
|
{
|
||||||
|
result.Append(" - ").Append(tag);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return result.ToString();
|
||||||
}
|
}
|
||||||
|
|
||||||
return string.Join(" - ", attributes.ToArray());
|
return string.Join(" - ", attributes.ToArray());
|
||||||
|
|
Loading…
Reference in New Issue
Block a user