fix: trim the variable to avoid the effects of whitespace characters
This commit is contained in:
parent
2ab5dea8ba
commit
5fa545e981
@ -175,7 +175,7 @@ public class AuthService(ICacheService cache, IAccessToken accessTokenService, I
|
||||
public async Task<TwoFactorAuthenticator> LoginAsync(CookieOptionsParameters cookieOptions, User user, HttpContext context, string password, string username, CancellationToken cancellation = default)
|
||||
{
|
||||
var requestContext = new RequestContextInfo(context, cookieOptions);
|
||||
|
||||
username = username.Trim();
|
||||
await VerifyUserOrThrowError(requestContext, user, password, username, cancellation);
|
||||
|
||||
if (user.TwoFactorAuthenticator == TwoFactorAuthenticator.None)
|
||||
|
Loading…
x
Reference in New Issue
Block a user