소스 검색

Only remove keyframe cache dir if it exists (#13834)

Tim Eisele 2 달 전
부모
커밋
0bde7bae05
1개의 변경된 파일4개의 추가작업 그리고 1개의 파일을 삭제
  1. 4 1
      Jellyfin.Server/Migrations/Routines/MigrateKeyframeData.cs

+ 4 - 1
Jellyfin.Server/Migrations/Routines/MigrateKeyframeData.cs

@@ -110,7 +110,10 @@ public class MigrateKeyframeData : IDatabaseMigrationRoutine
 
         _logger.LogInformation("Imported keyframes for {Count} items in {Time}", itemCount, sw.Elapsed);
 
-        Directory.Delete(KeyframeCachePath, true);
+        if (Directory.Exists(KeyframeCachePath))
+        {
+            Directory.Delete(KeyframeCachePath, true);
+        }
     }
 
     private bool TryGetKeyframeData(BaseItem item, [NotNullWhen(true)] out KeyframeData? data)