Remove GetImageTypes

This commit is contained in:
crobibero 2020-11-09 15:01:30 -07:00
parent b22831f7e5
commit 2ce9a56cae

View File

@ -165,33 +165,6 @@ namespace Jellyfin.Api.Helpers
.ToArray(); .ToArray();
} }
/// <summary>
/// Gets the item fields.
/// </summary>
/// <param name="imageTypes">The image types string.</param>
/// <returns>IEnumerable{ItemFields}.</returns>
internal static ImageType[] GetImageTypes(string? imageTypes)
{
if (string.IsNullOrEmpty(imageTypes))
{
return Array.Empty<ImageType>();
}
return Split(imageTypes, ',', true)
.Select(v =>
{
if (Enum.TryParse(v, true, out ImageType value))
{
return (ImageType?)value;
}
return null;
})
.Where(i => i.HasValue)
.Select(i => i!.Value)
.ToArray();
}
internal static QueryResult<BaseItemDto> CreateQueryResult( internal static QueryResult<BaseItemDto> CreateQueryResult(
QueryResult<(BaseItem, ItemCounts)> result, QueryResult<(BaseItem, ItemCounts)> result,
DtoOptions dtoOptions, DtoOptions dtoOptions,