Username is now case-insensitive in /give command

This commit is contained in:
Robin Kanters 2015-05-05 21:15:05 +02:00
parent bd2c4a9fc5
commit db27404b84

View File

@ -33,7 +33,7 @@ namespace TrueCraft.Commands
return;
}
var receiver = Client.Server.Clients.SingleOrDefault(c => c.Username == Arguments[1]);
var receiver = Client.Server.Clients.SingleOrDefault(c => String.Equals(c.Username, Arguments[1], StringComparison.CurrentCultureIgnoreCase));
short id;
sbyte count;
if (short.TryParse(Arguments[2], out id) && sbyte.TryParse(Arguments[3], out count))