Fix task CleanupCollectionAndPlaylistPathsTask removing valid paths (#11410)

pull/11423/head
John M 2 weeks ago committed by GitHub
parent f26eb15be0
commit c791331952
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -116,7 +116,7 @@ public class CleanupCollectionAndPlaylistPathsTask : IScheduledTask
foreach (var linkedChild in folder.LinkedChildren)
{
var path = linkedChild.Path;
if (Path.HasExtension(path) ? !File.Exists(path) : !Directory.Exists(path))
if (!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);

Loading…
Cancel
Save