aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Jellyfin.Server/Migrations/Routines/MigrateLinkedChildren.cs5
1 files changed, 3 insertions, 2 deletions
diff --git a/Jellyfin.Server/Migrations/Routines/MigrateLinkedChildren.cs b/Jellyfin.Server/Migrations/Routines/MigrateLinkedChildren.cs
index f9d31d8220..2048ad1b57 100644
--- a/Jellyfin.Server/Migrations/Routines/MigrateLinkedChildren.cs
+++ b/Jellyfin.Server/Migrations/Routines/MigrateLinkedChildren.cs
@@ -404,8 +404,9 @@ internal class MigrateLinkedChildren : IDatabaseMigrationRoutine
if (accessiblePaths.Any(p => path.StartsWith(p, StringComparison.OrdinalIgnoreCase)))
{
- // Item is under an accessible library location — check if the file still exists
- if (!File.Exists(path))
+ // Item is under an accessible library location — check if it still exists
+ // Directory check covers BDMV/DVD items whose Path points to a folder
+ if (!File.Exists(path) && !Directory.Exists(path))
{
staleIds.Add(item.Id);
}