aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Controller/Entities/Folder.cs
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Controller/Entities/Folder.cs')
-rw-r--r--MediaBrowser.Controller/Entities/Folder.cs26
1 files changed, 8 insertions, 18 deletions
diff --git a/MediaBrowser.Controller/Entities/Folder.cs b/MediaBrowser.Controller/Entities/Folder.cs
index f1d8def4b..d1e089850 100644
--- a/MediaBrowser.Controller/Entities/Folder.cs
+++ b/MediaBrowser.Controller/Entities/Folder.cs
@@ -1149,29 +1149,19 @@ namespace MediaBrowser.Controller.Entities
return LinkedChildren
.Select(i =>
{
- var requiresPostFilter = true;
-
- if (!string.IsNullOrWhiteSpace(i.Path))
- {
- requiresPostFilter = false;
-
- if (!locations.Any(l => FileSystem.ContainsSubPath(l, i.Path)))
- {
- return null;
- }
- }
-
var child = GetLinkedChild(i);
- if (requiresPostFilter && child != null)
+ if (child != null)
{
- if (string.IsNullOrWhiteSpace(child.Path))
+ var childLocationType = child.LocationType;
+ if (childLocationType == LocationType.Remote || childLocationType == LocationType.Virtual)
{
- Logger.Debug("Found LinkedChild with null path: {0}", child.Name);
- return child;
+ if (!child.IsVisibleStandalone(user))
+ {
+ return null;
+ }
}
-
- if (!locations.Any(l => FileSystem.ContainsSubPath(l, child.Path)))
+ else if (childLocationType == LocationType.FileSystem && !locations.Any(l => FileSystem.ContainsSubPath(l, child.Path)))
{
return null;
}