aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/Library/UserManager.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Emby.Server.Implementations/Library/UserManager.cs')
-rw-r--r--Emby.Server.Implementations/Library/UserManager.cs8
1 files changed, 4 insertions, 4 deletions
diff --git a/Emby.Server.Implementations/Library/UserManager.cs b/Emby.Server.Implementations/Library/UserManager.cs
index 656eeb145..25d733a65 100644
--- a/Emby.Server.Implementations/Library/UserManager.cs
+++ b/Emby.Server.Implementations/Library/UserManager.cs
@@ -1,5 +1,4 @@
#pragma warning disable CS1591
-#pragma warning disable SA1600
using System;
using System.Collections.Concurrent;
@@ -291,10 +290,11 @@ namespace Emby.Server.Implementations.Library
&& authenticationProvider != null
&& !(authenticationProvider is DefaultAuthenticationProvider))
{
- // We should trust the user that the authprovider says, not what was typed
+ // Trust the username returned by the authentication provider
username = updatedUsername;
- // Search the database for the user again; the authprovider might have created it
+ // Search the database for the user again
+ // the authentication provider might have created it
user = Users
.FirstOrDefault(i => string.Equals(username, i.Name, StringComparison.OrdinalIgnoreCase));
@@ -667,7 +667,7 @@ namespace Emby.Server.Implementations.Library
throw new ArgumentException("Invalid username", nameof(newName));
}
- if (user.Name.Equals(newName, StringComparison.OrdinalIgnoreCase))
+ if (user.Name.Equals(newName, StringComparison.Ordinal))
{
throw new ArgumentException("The new and old names must be different.");
}