diff options
author | Jesse Plamondon-Willard <Pathoschild@users.noreply.github.com> | 2020-09-27 13:23:48 -0400 |
---|---|---|
committer | Jesse Plamondon-Willard <Pathoschild@users.noreply.github.com> | 2020-09-27 13:23:48 -0400 |
commit | 5c733af7478db7c4a5b578512b4236e021b2abc9 (patch) | |
tree | ab7a3f1b3ec8b81d059c5a180239be4ea9857101 /src/SMAPI.Web/Framework/Clients/Chucklefish/ChucklefishClient.cs | |
parent | 4eff88fe73760ef89423de76cae80ffeee235240 (diff) | |
download | SMAPI-5c733af7478db7c4a5b578512b4236e021b2abc9.tar.gz SMAPI-5c733af7478db7c4a5b578512b4236e021b2abc9.tar.bz2 SMAPI-5c733af7478db7c4a5b578512b4236e021b2abc9.zip |
fix update-check error for Chucklefish mods due to site change
Diffstat (limited to 'src/SMAPI.Web/Framework/Clients/Chucklefish/ChucklefishClient.cs')
-rw-r--r-- | src/SMAPI.Web/Framework/Clients/Chucklefish/ChucklefishClient.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/SMAPI.Web/Framework/Clients/Chucklefish/ChucklefishClient.cs b/src/SMAPI.Web/Framework/Clients/Chucklefish/ChucklefishClient.cs index ca156da4..b8b05878 100644 --- a/src/SMAPI.Web/Framework/Clients/Chucklefish/ChucklefishClient.cs +++ b/src/SMAPI.Web/Framework/Clients/Chucklefish/ChucklefishClient.cs @@ -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>()); |