mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-02 22:08:27 +01:00
reduce locking on folder children
This commit is contained in:
@@ -1346,7 +1346,16 @@ namespace MediaBrowser.Server.Implementations.Library
|
||||
/// <returns>BaseItem.</returns>
|
||||
public BaseItem RetrieveItem(Guid id)
|
||||
{
|
||||
return ItemRepository.RetrieveItem(id);
|
||||
var item = ItemRepository.RetrieveItem(id);
|
||||
|
||||
var folder = item as Folder;
|
||||
|
||||
if (folder != null)
|
||||
{
|
||||
folder.LoadSavedChildren();
|
||||
}
|
||||
|
||||
return item;
|
||||
}
|
||||
|
||||
private readonly ConcurrentDictionary<string, SemaphoreSlim> _fileLocks = new ConcurrentDictionary<string, SemaphoreSlim>();
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace MediaBrowser.Server.Implementations.Library
|
||||
/// <param name="args">The args.</param>
|
||||
public static void SetInitialItemValues(BaseItem item, ItemResolveArgs args)
|
||||
{
|
||||
item.ResolveArgs = args;
|
||||
item.ResetResolveArgs(args);
|
||||
|
||||
// If the resolver didn't specify this
|
||||
if (string.IsNullOrEmpty(item.Path))
|
||||
|
||||
Reference in New Issue
Block a user