mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-11-15 18:08:53 -07:00
Don't run series and movie resolvers against VF's
This commit is contained in:
parent
a0d69b3804
commit
578ec7c5a5
@ -116,7 +116,7 @@ namespace MediaBrowser.Api
|
||||
dto.SpecialCounts = folder.GetSpecialCounts(user);
|
||||
|
||||
dto.IsRoot = folder.IsRoot;
|
||||
dto.IsVirtualFolder = folder.Parent != null && folder.Parent.IsRoot;
|
||||
dto.IsVirtualFolder = folder.IsVirtualFolder;
|
||||
}
|
||||
|
||||
Audio audio = item as Audio;
|
||||
|
@ -16,6 +16,14 @@ namespace MediaBrowser.Model.Entities
|
||||
|
||||
public bool IsRoot { get; set; }
|
||||
|
||||
public bool IsVirtualFolder
|
||||
{
|
||||
get
|
||||
{
|
||||
return Parent != null && Parent.IsRoot;
|
||||
}
|
||||
}
|
||||
|
||||
public IEnumerable<BaseItem> Children { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -24,6 +24,12 @@ namespace MediaBrowser.Movies.Resolvers
|
||||
}
|
||||
}
|
||||
|
||||
// Optimization to avoid running all these tests against VF's
|
||||
if (args.Parent != null && args.Parent.IsVirtualFolder)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
// Return a movie if the video resolver finds something in the folder
|
||||
return GetMovie(args);
|
||||
}
|
||||
|
@ -15,6 +15,12 @@ namespace MediaBrowser.TV.Resolvers
|
||||
{
|
||||
if (args.IsDirectory)
|
||||
{
|
||||
// Optimization to avoid running all these tests against VF's
|
||||
if (args.Parent != null && args.Parent.IsVirtualFolder)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
// Optimization to avoid running these tests against Seasons
|
||||
if (args.Parent is Series)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user