summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--docs/release-notes.md4
-rw-r--r--src/SMAPI.Toolkit/Utilities/PathUtilities.cs3
2 files changed, 7 insertions, 0 deletions
diff --git a/docs/release-notes.md b/docs/release-notes.md
index ed03b3db..6112f99c 100644
--- a/docs/release-notes.md
+++ b/docs/release-notes.md
@@ -7,6 +7,10 @@
* Migrated to Harmony 2.0 (see [_migrate to Harmony 2.0_](https://stardewvalleywiki.com/Modding:Migrate_to_Harmony_2.0) for more info).
-->
+## Upcoming release
+* For players:
+ * Fixed installer error if the `Mods` folder doesn't exist in 3.9.3.
+
## 3.9.3
Released 07 March 2021 for Stardew Valley 1.5.4 or later.
diff --git a/src/SMAPI.Toolkit/Utilities/PathUtilities.cs b/src/SMAPI.Toolkit/Utilities/PathUtilities.cs
index a394edba..babc0981 100644
--- a/src/SMAPI.Toolkit/Utilities/PathUtilities.cs
+++ b/src/SMAPI.Toolkit/Utilities/PathUtilities.cs
@@ -139,6 +139,9 @@ namespace StardewModdingAPI.Toolkit.Utilities
/// <param name="rootPath">The root path to search.</param>
internal static IEnumerable<string> GetTooLongPaths(string rootPath)
{
+ if (!Directory.Exists(rootPath))
+ return new string[0];
+
return Directory
.EnumerateFileSystemEntries(rootPath, "*.*", SearchOption.AllDirectories)
.Where(PathUtilities.IsPathTooLong);