diff options
author | Jesse Plamondon-Willard <Pathoschild@users.noreply.github.com> | 2019-02-24 16:29:50 -0500 |
---|---|---|
committer | Jesse Plamondon-Willard <Pathoschild@users.noreply.github.com> | 2019-02-24 18:44:24 -0500 |
commit | c7cb7ebb8112f848c3f66f7ae98c9ec0139935aa (patch) | |
tree | ab884e32c6f95243705e7137c63ca83a2171f0b4 | |
parent | c24946c3993c0680153bbf9e536593cc80fc16f0 (diff) | |
download | SMAPI-c7cb7ebb8112f848c3f66f7ae98c9ec0139935aa.tar.gz SMAPI-c7cb7ebb8112f848c3f66f7ae98c9ec0139935aa.tar.bz2 SMAPI-c7cb7ebb8112f848c3f66f7ae98c9ec0139935aa.zip |
fix smapi.io linking to an archived download in rare cases
-rw-r--r-- | docs/release-notes.md | 1 | ||||
-rw-r--r-- | src/SMAPI.Web/Controllers/IndexController.cs | 3 |
2 files changed, 4 insertions, 0 deletions
diff --git a/docs/release-notes.md b/docs/release-notes.md index 72477df1..dce1e715 100644 --- a/docs/release-notes.md +++ b/docs/release-notes.md @@ -11,6 +11,7 @@ Currently in beta for Stardew Valley 1.3.35-beta only. **Not compatible with non * For the web UI: * The log parser now displays available updates in a section at the top. * Mod compatibility page now crosses out mod links if they're outdated to prevent confusion. + * Fixed smapi.io linking to an archived download in rare cases. ## 2.10.2 Released 09 January 2019 for Stardew Valley 1.3.32–33. diff --git a/src/SMAPI.Web/Controllers/IndexController.cs b/src/SMAPI.Web/Controllers/IndexController.cs index 7b3b3e80..ea1a52b2 100644 --- a/src/SMAPI.Web/Controllers/IndexController.cs +++ b/src/SMAPI.Web/Controllers/IndexController.cs @@ -141,6 +141,9 @@ namespace StardewModdingAPI.Web.Controllers foreach (GitAsset asset in release.Assets) { + if (asset.FileName.StartsWith("Z_OLD")) + continue; + Match match = Regex.Match(asset.FileName, @"SMAPI-(?<version>[\d\.]+(?:-.+)?)-installer(?<forDevs>-for-developers)?.zip"); if (!match.Success || !SemanticVersion.TryParse(match.Groups["version"].Value, out ISemanticVersion version)) continue; |