update special folders
This commit is contained in:
parent
23d65f4871
commit
bed740668c
|
@ -128,7 +128,7 @@ namespace MediaBrowser.Controller.Entities
|
|||
/// <returns>IEnumerable{BaseItem}.</returns>
|
||||
protected override IEnumerable<BaseItem> GetNonCachedChildren(IDirectoryService directoryService)
|
||||
{
|
||||
return base.GetNonCachedChildren(directoryService);
|
||||
return base.GetNonCachedChildren(directoryService).Concat(_virtualChildren);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
|
@ -55,13 +55,18 @@ namespace MediaBrowser.Controller.Entities
|
|||
}
|
||||
}
|
||||
|
||||
protected override IEnumerable<BaseItem> GetEligibleChildrenForRecursiveChildren(User user)
|
||||
{
|
||||
return base.GetEligibleChildrenForRecursiveChildren(user).Concat(LibraryManager.RootFolder.VirtualChildren);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Get the children of this folder from the actual file system
|
||||
/// </summary>
|
||||
/// <returns>IEnumerable{BaseItem}.</returns>
|
||||
protected override IEnumerable<BaseItem> GetNonCachedChildren(IDirectoryService directoryService)
|
||||
{
|
||||
return base.GetNonCachedChildren(directoryService).Concat(LibraryManager.RootFolder.VirtualChildren);
|
||||
return base.GetNonCachedChildren(directoryService);
|
||||
}
|
||||
|
||||
public override bool BeforeMetadataRefresh()
|
||||
|
|
|
@ -727,12 +727,12 @@ namespace MediaBrowser.Server.Implementations.Library
|
|||
folder = dbItem;
|
||||
}
|
||||
|
||||
//if (folder.ParentId != rootFolder.Id)
|
||||
//{
|
||||
// folder.ParentId = rootFolder.Id;
|
||||
// var task = folder.UpdateToRepository(ItemUpdateType.MetadataImport, CancellationToken.None);
|
||||
// Task.WaitAll(task);
|
||||
//}
|
||||
if (folder.ParentId != rootFolder.Id)
|
||||
{
|
||||
folder.ParentId = rootFolder.Id;
|
||||
var task = folder.UpdateToRepository(ItemUpdateType.MetadataImport, CancellationToken.None);
|
||||
Task.WaitAll(task);
|
||||
}
|
||||
|
||||
rootFolder.AddVirtualChild(folder);
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user