Add remote trailer to xml

pull/702/head
Luke Pulverenti 12 years ago
parent cf61bf72dc
commit 414e344f4b

@ -70,7 +70,8 @@ namespace MediaBrowser.Providers.Savers
"Studios", "Studios",
"Tags", "Tags",
"Added", "Added",
"LockData" "LockData",
"Trailer"
}); });
var position = xml.ToString().LastIndexOf("</", StringComparison.OrdinalIgnoreCase); var position = xml.ToString().LastIndexOf("</", StringComparison.OrdinalIgnoreCase);
@ -158,7 +159,7 @@ namespace MediaBrowser.Providers.Savers
builder.Append("<Added>" + SecurityElement.Escape(item.DateCreated.ToString(UsCulture)) + "</Added>"); builder.Append("<Added>" + SecurityElement.Escape(item.DateCreated.ToString(UsCulture)) + "</Added>");
builder.Append("<LockData>" + item.DontFetchMeta.ToString().ToLower() + "</LockData>"); builder.Append("<LockData>" + item.DontFetchMeta.ToString().ToLower() + "</LockData>");
if (!string.IsNullOrEmpty(item.DisplayMediaType)) if (!string.IsNullOrEmpty(item.DisplayMediaType))
{ {
builder.Append("<Type>" + SecurityElement.Escape(item.DisplayMediaType) + "</Type>"); builder.Append("<Type>" + SecurityElement.Escape(item.DisplayMediaType) + "</Type>");
@ -199,6 +200,11 @@ namespace MediaBrowser.Providers.Savers
builder.Append("<PremiereDate>" + SecurityElement.Escape(item.PremiereDate.Value.ToString("yyyy-MM-dd")) + "</PremiereDate>"); builder.Append("<PremiereDate>" + SecurityElement.Escape(item.PremiereDate.Value.ToString("yyyy-MM-dd")) + "</PremiereDate>");
} }
if (item.RemoteTrailers.Count > 0)
{
builder.Append("<Trailer>" + SecurityElement.Escape(item.RemoteTrailers[0].Url) + "</Trailer>");
}
if (item.Budget.HasValue) if (item.Budget.HasValue)
{ {
builder.Append("<Budget>" + SecurityElement.Escape(item.Budget.Value.ToString(UsCulture)) + "</Budget>"); builder.Append("<Budget>" + SecurityElement.Escape(item.Budget.Value.ToString(UsCulture)) + "</Budget>");

Loading…
Cancel
Save