summaryrefslogtreecommitdiff
path: root/src/SMAPI.Toolkit
diff options
context:
space:
mode:
authorNuz / Lovegood <nuztalgia@gmail.com>2022-04-10 23:34:50 -0700
committerNuz / Lovegood <nuztalgia@gmail.com>2022-04-10 23:34:50 -0700
commit25e0b4b8ada9ce7aa02f9eafaf5e0609977685c4 (patch)
tree3696bae66817953d530c029532e22423a093d9a2 /src/SMAPI.Toolkit
parent2a05e287821c3ce48a79705d39d190b84c48d361 (diff)
downloadSMAPI-25e0b4b8ada9ce7aa02f9eafaf5e0609977685c4.tar.gz
SMAPI-25e0b4b8ada9ce7aa02f9eafaf5e0609977685c4.tar.bz2
SMAPI-25e0b4b8ada9ce7aa02f9eafaf5e0609977685c4.zip
Make IsRelevant return false for any files starting with "."
Diffstat (limited to 'src/SMAPI.Toolkit')
-rw-r--r--src/SMAPI.Toolkit/Framework/ModScanning/ModScanner.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/SMAPI.Toolkit/Framework/ModScanning/ModScanner.cs b/src/SMAPI.Toolkit/Framework/ModScanning/ModScanner.cs
index 2af30092..12333c4e 100644
--- a/src/SMAPI.Toolkit/Framework/ModScanning/ModScanner.cs
+++ b/src/SMAPI.Toolkit/Framework/ModScanning/ModScanner.cs
@@ -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