diff options
| author | Luke <luke.pulverenti@gmail.com> | 2017-09-07 14:18:09 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-09-07 14:18:09 -0400 |
| commit | 890069d312d3132391edf857730ffc9a34c9fce4 (patch) | |
| tree | a46e31f6f2d155411a24e4ff3685013512a078e9 /MediaBrowser.Controller/Entities | |
| parent | 5116b175ce4a1f3a54c64c6f8fa8e8fba1a69e1a (diff) | |
| parent | 6392f5e141b9971f7d69cc74e08118889d6d5580 (diff) | |
Merge pull request #2869 from MediaBrowser/dev
Dev
Diffstat (limited to 'MediaBrowser.Controller/Entities')
| -rw-r--r-- | MediaBrowser.Controller/Entities/Movies/BoxSet.cs | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/MediaBrowser.Controller/Entities/Movies/BoxSet.cs b/MediaBrowser.Controller/Entities/Movies/BoxSet.cs index 900e8a6646..bd8d9024d4 100644 --- a/MediaBrowser.Controller/Entities/Movies/BoxSet.cs +++ b/MediaBrowser.Controller/Entities/Movies/BoxSet.cs @@ -80,16 +80,44 @@ namespace MediaBrowser.Controller.Entities.Movies protected override IEnumerable<BaseItem> GetNonCachedChildren(IDirectoryService directoryService) { + if (IsLegacyBoxSet) + { + return base.GetNonCachedChildren(directoryService); + } return new List<BaseItem>(); } protected override List<BaseItem> LoadChildren() { + if (IsLegacyBoxSet) + { + return base.LoadChildren(); + } + // Save a trip to the database return new List<BaseItem>(); } [IgnoreDataMember] + private bool IsLegacyBoxSet + { + get + { + if (string.IsNullOrWhiteSpace(Path)) + { + return false; + } + + if (LinkedChildren.Length > 0) + { + return false; + } + + return !FileSystem.ContainsSubPath(ConfigurationManager.ApplicationPaths.DataPath, Path); + } + } + + [IgnoreDataMember] public override bool IsPreSorted { get |
