mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-12-18 06:53:07 +03:00
improve live tv images
This commit is contained in:
@@ -27,6 +27,7 @@ using MediaBrowser.Controller.Configuration;
|
||||
using MediaBrowser.Controller.IO;
|
||||
using MediaBrowser.Model.Globalization;
|
||||
using MediaBrowser.Model.Services;
|
||||
using MediaBrowser.Common.Extensions;
|
||||
|
||||
namespace MediaBrowser.Api.Library
|
||||
{
|
||||
@@ -830,6 +831,11 @@ namespace MediaBrowser.Api.Library
|
||||
: (Folder)_libraryManager.RootFolder)
|
||||
: _libraryManager.GetItemById(request.Id);
|
||||
|
||||
if (item == null)
|
||||
{
|
||||
throw new ResourceNotFoundException("Item not found.");
|
||||
}
|
||||
|
||||
while (item.ThemeSongIds.Count == 0 && request.InheritFromParent && item.GetParent() != null)
|
||||
{
|
||||
item = item.GetParent();
|
||||
@@ -874,6 +880,11 @@ namespace MediaBrowser.Api.Library
|
||||
: (Folder)_libraryManager.RootFolder)
|
||||
: _libraryManager.GetItemById(request.Id);
|
||||
|
||||
if (item == null)
|
||||
{
|
||||
throw new ResourceNotFoundException("Item not found.");
|
||||
}
|
||||
|
||||
while (item.ThemeVideoIds.Count == 0 && request.InheritFromParent && item.GetParent() != null)
|
||||
{
|
||||
item = item.GetParent();
|
||||
|
||||
Reference in New Issue
Block a user