From 898be1f28f7e9fac71f6accac2efe4c0af99e495 Mon Sep 17 00:00:00 2001 From: Mikal Stordal Date: Tue, 5 Nov 2024 23:39:14 +0100 Subject: [PATCH] fix: fix dir exists checks for trickplay directory in vfs --- Shokofin/Resolvers/VirtualFileSystemService.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Shokofin/Resolvers/VirtualFileSystemService.cs b/Shokofin/Resolvers/VirtualFileSystemService.cs index a7b1ba9d..540051e1 100644 --- a/Shokofin/Resolvers/VirtualFileSystemService.cs +++ b/Shokofin/Resolvers/VirtualFileSystemService.cs @@ -927,11 +927,11 @@ public LinkGenerationResult GenerateSymbolicLinks(string sourceLocation, string[ } var trickplayLocation = Path.ChangeExtension(sourceLocation, ".trickplay"); - if (File.Exists(trickplayLocation)) { + if (Directory.Exists(trickplayLocation)) { var symbolicName = Path.GetFileNameWithoutExtension(symbolicLink); var symbolicTrickplay = Path.Join(symbolicDirectory, symbolicName + ".trickplay"); result.Paths.Add(symbolicTrickplay); - if (!File.Exists(symbolicTrickplay)) { + if (!Directory.Exists(symbolicTrickplay)) { result.CreatedTrickplayDirectories++; if (!preview) { Logger.LogDebug("Linking {Link} → {LinkTarget}", symbolicTrickplay, trickplayLocation);