diff options
| author | crobibero <cody@robibe.ro> | 2020-07-19 20:21:30 -0600 |
|---|---|---|
| committer | crobibero <cody@robibe.ro> | 2020-07-19 20:21:30 -0600 |
| commit | d1e351a00ac47c2caa7e7e1a22e20c65d27cec7f (patch) | |
| tree | d3fab59cf59243074ad3828cef4d0030303b9784 | |
| parent | 8ac08499bc47caf17d029fe10605da6c335a48e5 (diff) | |
Fix username case change
| -rw-r--r-- | Jellyfin.Server.Implementations/Users/UserManager.cs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Jellyfin.Server.Implementations/Users/UserManager.cs b/Jellyfin.Server.Implementations/Users/UserManager.cs index e3a7d5467..343f452c7 100644 --- a/Jellyfin.Server.Implementations/Users/UserManager.cs +++ b/Jellyfin.Server.Implementations/Users/UserManager.cs @@ -152,12 +152,12 @@ namespace Jellyfin.Server.Implementations.Users throw new ArgumentException("Invalid username", nameof(newName)); } - if (user.Username.Equals(newName, StringComparison.OrdinalIgnoreCase)) + if (user.Username.Equals(newName, StringComparison.Ordinal)) { throw new ArgumentException("The new and old names must be different."); } - if (Users.Any(u => u.Id != user.Id && u.Username.Equals(newName, StringComparison.OrdinalIgnoreCase))) + if (Users.Any(u => u.Id != user.Id && u.Username.Equals(newName, StringComparison.Ordinal))) { throw new ArgumentException(string.Format( CultureInfo.InvariantCulture, |
