fix update-check error for Chucklefish mods due to site change

This commit is contained in:
Jesse Plamondon-Willard 2020-09-27 13:23:48 -04:00
parent 4eff88fe73
commit 5c733af747
No known key found for this signature in database
GPG Key ID: CF8B1456B3E29F49
2 changed files with 7 additions and 6 deletions

View File

@ -9,17 +9,18 @@
## Upcoming release
* For players:
* Improved performance of exit handler (thanks to millerscout!).
* Improved performance on some older computers (thanks to millerscout!).
* Fixed update alerts for Chucklefish forum mods broken by a recent site change.
* For modders:
* Fixed asset propagation for `Data\MoviesReactions`.
* Fixed error in the case-insensitive content pack logic when a mod reads a null file path. (It now correctly logs an error in the code that handles the path instead.)
* Fixed error in content pack path handling when you pass a null path.
* For the web UI:
* Updated the JSON validator/schema for Content Patcher 1.18.
* For SMAPI developers:
* Reworked how the _mod build config_ package is released, added auto-generated package on build.
* Simplified preparing a mod build config package release.
## 3.7.3
Released 16 September 2020 for Stardew Valley 1.4.1 or later.

View File

@ -67,10 +67,10 @@ namespace StardewModdingAPI.Web.Framework.Clients.Chucklefish
// extract mod info
string url = this.GetModUrl(parsedId);
string name = doc.DocumentNode.SelectSingleNode("//meta[@name='twitter:title']").Attributes["content"].Value;
if (name.StartsWith("[SMAPI] "))
name = name.Substring("[SMAPI] ".Length);
string version = doc.DocumentNode.SelectSingleNode("//h1/span")?.InnerText;
string name = doc.DocumentNode.SelectSingleNode("//h1").ChildNodes[0].InnerText.Trim();
if (name.StartsWith("[SMAPI]"))
name = name.Substring("[SMAPI]".Length).TrimStart();
// return info
return page.SetInfo(name: name, version: version, url: url, downloads: Array.Empty<IModDownload>());