summaryrefslogtreecommitdiff
path: root/src/SMAPI.Mods.ConsoleCommands/Framework/Commands
diff options
context:
space:
mode:
authorJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2020-07-26 02:50:20 -0400
committerJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2020-07-26 02:50:20 -0400
commit7900a84bd68d7c9450bba719ce925b61043875f3 (patch)
tree8c495b7fe1c29c0cb552dc657a7a8b61185be0bd /src/SMAPI.Mods.ConsoleCommands/Framework/Commands
parentee4c88f6016b6bc0d72e0d459f6b918bdd7728f3 (diff)
downloadSMAPI-7900a84bd68d7c9450bba719ce925b61043875f3.tar.gz
SMAPI-7900a84bd68d7c9450bba719ce925b61043875f3.tar.bz2
SMAPI-7900a84bd68d7c9450bba719ce925b61043875f3.zip
use ordinal comparison/sorting instead of invariant
Diffstat (limited to 'src/SMAPI.Mods.ConsoleCommands/Framework/Commands')
-rw-r--r--src/SMAPI.Mods.ConsoleCommands/Framework/Commands/ArgumentParser.cs2
-rw-r--r--src/SMAPI.Mods.ConsoleCommands/Framework/Commands/World/ClearCommand.cs2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/SMAPI.Mods.ConsoleCommands/Framework/Commands/ArgumentParser.cs b/src/SMAPI.Mods.ConsoleCommands/Framework/Commands/ArgumentParser.cs
index 9c7082c9..e84445d7 100644
--- a/src/SMAPI.Mods.ConsoleCommands/Framework/Commands/ArgumentParser.cs
+++ b/src/SMAPI.Mods.ConsoleCommands/Framework/Commands/ArgumentParser.cs
@@ -64,7 +64,7 @@ namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands
this.LogError($"Argument {index} ({name}) is required.");
return false;
}
- if (oneOf?.Any() == true && !oneOf.Contains(this.Args[index], StringComparer.InvariantCultureIgnoreCase))
+ if (oneOf?.Any() == true && !oneOf.Contains(this.Args[index], StringComparer.OrdinalIgnoreCase))
{
this.LogError($"Argument {index} ({name}) must be one of {string.Join(", ", oneOf)}.");
return false;
diff --git a/src/SMAPI.Mods.ConsoleCommands/Framework/Commands/World/ClearCommand.cs b/src/SMAPI.Mods.ConsoleCommands/Framework/Commands/World/ClearCommand.cs
index e9545575..1190a4ab 100644
--- a/src/SMAPI.Mods.ConsoleCommands/Framework/Commands/World/ClearCommand.cs
+++ b/src/SMAPI.Mods.ConsoleCommands/Framework/Commands/World/ClearCommand.cs
@@ -56,7 +56,7 @@ namespace StardewModdingAPI.Mods.ConsoleCommands.Framework.Commands.World
return;
// get target location
- GameLocation location = Game1.locations.FirstOrDefault(p => p.Name != null && p.Name.Equals(locationName, StringComparison.InvariantCultureIgnoreCase));
+ GameLocation location = Game1.locations.FirstOrDefault(p => p.Name != null && p.Name.Equals(locationName, StringComparison.OrdinalIgnoreCase));
if (location == null && locationName == "current")
location = Game1.currentLocation;
if (location == null)