Remove GetImageTypes
This commit is contained in:
parent
b22831f7e5
commit
2ce9a56cae
|
@ -165,33 +165,6 @@ namespace Jellyfin.Api.Helpers
|
|||
.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(
|
||||
QueryResult<(BaseItem, ItemCounts)> result,
|
||||
DtoOptions dtoOptions,
|
||||
|
|
Loading…
Reference in New Issue
Block a user