소스 검색

#11289 Fixed cleanup task not checking for folders (#11311)

JPVenson 1 년 전
부모
커밋
81d3758785
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      Emby.Server.Implementations/ScheduledTasks/Tasks/CleanupCollectionAndPlaylistPathsTask.cs

+ 1 - 1
Emby.Server.Implementations/ScheduledTasks/Tasks/CleanupCollectionAndPlaylistPathsTask.cs

@@ -116,7 +116,7 @@ public class CleanupCollectionAndPlaylistPathsTask : IScheduledTask
         foreach (var linkedChild in folder.LinkedChildren)
         {
             var path = linkedChild.Path;
-            if (!File.Exists(path))
+            if (Path.HasExtension(path) ? !File.Exists(path) : !Directory.Exists(path))
             {
                 _logger.LogInformation("Item in {FolderName} cannot be found at {ItemPath}", folder.Name, path);
                 (itemsToRemove ??= new List<LinkedChild>()).Add(linkedChild);