diff options
author | Jesse Plamondon-Willard <Pathoschild@users.noreply.github.com> | 2022-08-08 19:54:07 -0400 |
---|---|---|
committer | Jesse Plamondon-Willard <Pathoschild@users.noreply.github.com> | 2022-08-08 19:54:07 -0400 |
commit | 352fa4759e0b52ad25bd5d210639f57eabad6c89 (patch) | |
tree | 18298447e5c8562c2ee055313ee885c7fa731f71 /src | |
parent | 1749a82947c84fec253f7ca6016e8428cdcd87b1 (diff) | |
download | SMAPI-352fa4759e0b52ad25bd5d210639f57eabad6c89.tar.gz SMAPI-352fa4759e0b52ad25bd5d210639f57eabad6c89.tar.bz2 SMAPI-352fa4759e0b52ad25bd5d210639f57eabad6c89.zip |
fix error when a mod is both duplicated and missing the DLL
Diffstat (limited to 'src')
-rw-r--r-- | src/SMAPI/Framework/ModLoading/ModResolver.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/SMAPI/Framework/ModLoading/ModResolver.cs b/src/SMAPI/Framework/ModLoading/ModResolver.cs index abc46d47..a487ba28 100644 --- a/src/SMAPI/Framework/ModLoading/ModResolver.cs +++ b/src/SMAPI/Framework/ModLoading/ModResolver.cs @@ -47,7 +47,7 @@ namespace StardewModdingAPI.Framework.ModLoading IModMetadata metadata = new ModMetadata(folder.DisplayName, folder.Directory.FullName, rootPath, manifest, dataRecord, isIgnored: shouldIgnore); if (shouldIgnore) metadata.SetStatus(status, ModFailReason.DisabledByDotConvention, "disabled by dot convention"); - else + else if (metadata.Status == ModMetadataStatus.Failed) metadata.SetStatus(status, ModFailReason.InvalidManifest, folder.ManifestParseErrorText); yield return metadata; @@ -223,8 +223,8 @@ namespace StardewModdingAPI.Framework.ModLoading { foreach (IModMetadata mod in group) { - if (mod.Status == ModMetadataStatus.Failed) - continue; // don't replace metadata error + if (mod.Status == ModMetadataStatus.Failed && mod.FailReason != ModFailReason.InvalidManifest) + continue; string folderList = string.Join(", ", group.Select(p => p.GetRelativePathWithRoot()).OrderBy(p => p)); mod.SetStatus(ModMetadataStatus.Failed, ModFailReason.Duplicate, $"you have multiple copies of this mod installed. To fix this, delete these folders and reinstall the mod: {folderList}."); |