From 7900a84bd68d7c9450bba719ce925b61043875f3 Mon Sep 17 00:00:00 2001 From: Jesse Plamondon-Willard Date: Sun, 26 Jul 2020 02:50:20 -0400 Subject: use ordinal comparison/sorting instead of invariant --- src/SMAPI/Metadata/CoreAssetPropagator.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/SMAPI/Metadata/CoreAssetPropagator.cs') diff --git a/src/SMAPI/Metadata/CoreAssetPropagator.cs b/src/SMAPI/Metadata/CoreAssetPropagator.cs index fa6541cb..5c77bf66 100644 --- a/src/SMAPI/Metadata/CoreAssetPropagator.cs +++ b/src/SMAPI/Metadata/CoreAssetPropagator.cs @@ -84,7 +84,7 @@ namespace StardewModdingAPI.Metadata }); // reload assets - IDictionary propagated = assets.ToDictionary(p => p.Key, p => false, StringComparer.InvariantCultureIgnoreCase); + IDictionary propagated = assets.ToDictionary(p => p.Key, p => false, StringComparer.OrdinalIgnoreCase); foreach (var bucket in buckets) { switch (bucket.Key) @@ -779,7 +779,7 @@ namespace StardewModdingAPI.Metadata private void ReloadNpcSprites(LocalizedContentManager content, IEnumerable keys, IDictionary propagated) { // get NPCs - HashSet lookup = new HashSet(keys, StringComparer.InvariantCultureIgnoreCase); + HashSet lookup = new HashSet(keys, StringComparer.OrdinalIgnoreCase); var characters = ( from npc in this.GetCharacters() @@ -806,7 +806,7 @@ namespace StardewModdingAPI.Metadata private void ReloadNpcPortraits(LocalizedContentManager content, IEnumerable keys, IDictionary propagated) { // get NPCs - HashSet lookup = new HashSet(keys, StringComparer.InvariantCultureIgnoreCase); + HashSet lookup = new HashSet(keys, StringComparer.OrdinalIgnoreCase); var characters = ( from npc in this.GetCharacters() @@ -1031,7 +1031,7 @@ namespace StardewModdingAPI.Metadata if (string.IsNullOrWhiteSpace(key) || string.IsNullOrWhiteSpace(rawSubstring)) return false; - return key.StartsWith(this.NormalizeAssetNameIgnoringEmpty(rawSubstring), StringComparison.InvariantCultureIgnoreCase); + return key.StartsWith(this.NormalizeAssetNameIgnoringEmpty(rawSubstring), StringComparison.OrdinalIgnoreCase); } /// Get whether a normalized asset key is in the given folder. -- cgit