Make IsRelevant return false for any files starting with "."

This commit is contained in:
Nuz / Lovegood 2022-04-10 23:34:50 -07:00
parent 2a05e28782
commit 25e0b4b8ad
1 changed files with 2 additions and 2 deletions

View File

@ -306,8 +306,8 @@ namespace StardewModdingAPI.Toolkit.Framework.ModScanning
/// <param name="entry">The file or folder.</param>
private bool IsRelevant(FileSystemInfo entry)
{
// ignored file extension
if (entry is FileInfo file && this.IgnoreFileExtensions.Contains(file.Extension))
// ignored file extensions and any files starting with "."
if ((entry is FileInfo file) && (this.IgnoreFileExtensions.Contains(file.Extension) || file.Name.StartsWith(".")))
return false;
// ignored entry name