diff options
| author | Luke Pulverenti <luke.pulverenti@gmail.com> | 2017-04-06 16:07:25 -0400 |
|---|---|---|
| committer | Luke Pulverenti <luke.pulverenti@gmail.com> | 2017-04-06 16:07:25 -0400 |
| commit | ccb694a89ad5ba63fcae1c9634a55c1f0378d98c (patch) | |
| tree | b045a71d84deeb89a85975d34a7a2ded2642c0d5 /Emby.Server.Implementations/Session/SessionManager.cs | |
| parent | fd71890247ca34bbc2803ead6c75930d36379a13 (diff) | |
update home sections
Diffstat (limited to 'Emby.Server.Implementations/Session/SessionManager.cs')
| -rw-r--r-- | Emby.Server.Implementations/Session/SessionManager.cs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Emby.Server.Implementations/Session/SessionManager.cs b/Emby.Server.Implementations/Session/SessionManager.cs index 8051b7848..05a240cea 100644 --- a/Emby.Server.Implementations/Session/SessionManager.cs +++ b/Emby.Server.Implementations/Session/SessionManager.cs @@ -1404,12 +1404,14 @@ namespace Emby.Server.Implementations.Session { var result = await _userManager.AuthenticateUser(request.Username, request.PasswordSha1, request.PasswordMd5, request.RemoteEndPoint).ConfigureAwait(false); - if (!result) + if (result == null) { EventHelper.FireEventIfNotNull(AuthenticationFailed, this, new GenericEventArgs<AuthenticationRequest>(request), _logger); throw new SecurityException("Invalid user or password entered."); } + + user = result; } var token = await GetAuthorizationToken(user.Id.ToString("N"), request.DeviceId, request.App, request.AppVersion, request.DeviceName).ConfigureAwait(false); |
