From 4a4037323e9256cfcd1ddace530f616a269e4043 Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Thu, 17 Aug 2023 21:21:46 -0700 Subject: [PATCH] Fixed: Hidden files being ignored (cherry picked from commit d493f8762fcb1684b44e182753c21d7a493db787) Closes #9023 --- src/NzbDrone.Common/Disk/DiskProviderBase.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/NzbDrone.Common/Disk/DiskProviderBase.cs b/src/NzbDrone.Common/Disk/DiskProviderBase.cs index 7e0174b90..b9d6503e0 100644 --- a/src/NzbDrone.Common/Disk/DiskProviderBase.cs +++ b/src/NzbDrone.Common/Disk/DiskProviderBase.cs @@ -162,6 +162,7 @@ public IEnumerable GetFiles(string path, bool recursive) return Directory.EnumerateFiles(path, "*", new EnumerationOptions { + AttributesToSkip = FileAttributes.System, RecurseSubdirectories = recursive, IgnoreInaccessible = true }); @@ -528,6 +529,7 @@ public List GetFileInfos(string path, bool recursive = false) return di.EnumerateFiles("*", new EnumerationOptions { + AttributesToSkip = FileAttributes.System, RecurseSubdirectories = recursive, IgnoreInaccessible = true }).ToList();