fix log parser not recognising content packs with no description (#481)

This commit is contained in:
Jesse Plamondon-Willard 2018-05-02 17:58:48 -04:00
parent b1a24452ee
commit dc47ff15c5
2 changed files with 4 additions and 1 deletions

View File

@ -23,6 +23,9 @@
* Added `player_add name`, which lets you add items to your inventory by name instead of ID.
* Fixed `world_settime` sometimes breaking NPC schedules (e.g. so they stay in bed).
* For the log parser:
* Fixed issue parsing content packs with no description.
* For SMAPI developers:
* Added more consistent crossplatform handling using a new `EnvironmentUtility`, including MacOS detection.
* Added beta update channel to SMAPI, the web API, and home page.

View File

@ -37,7 +37,7 @@ namespace StardewModdingAPI.Web.Framework.LogParsing
private readonly Regex ContentPackListStartPattern = new Regex(@"^Loaded \d+ content packs:$", RegexOptions.Compiled | RegexOptions.IgnoreCase);
/// <summary>A regex pattern matching an entry in SMAPI's content pack list.</summary>
private readonly Regex ContentPackListEntryPattern = new Regex(@"^ (?<name>.+) (?<version>.+) by (?<author>.+) \| for (?<for>.+?) \| (?<description>.+)$", RegexOptions.Compiled | RegexOptions.IgnoreCase);
private readonly Regex ContentPackListEntryPattern = new Regex(@"^ (?<name>.+) (?<version>.+) by (?<author>.+) \| for (?<for>.+?)(?: \| (?<description>.+))?$", RegexOptions.Compiled | RegexOptions.IgnoreCase);
/*********