Enable nullable for AuthorizationInfo (#13485)

This commit is contained in:
Bond-009
2025-02-05 01:10:39 +01:00
committed by GitHub
parent 2de04cb07c
commit 00b66a06ea
6 changed files with 25 additions and 23 deletions

View File

@@ -116,17 +116,15 @@ namespace Jellyfin.Server.Implementations.Security
DeviceId = deviceId,
Version = version,
Token = token,
IsAuthenticated = false,
HasToken = false
IsAuthenticated = false
};
if (string.IsNullOrWhiteSpace(token))
if (!authInfo.HasToken)
{
// Request doesn't contain a token.
return authInfo;
}
authInfo.HasToken = true;
var dbContext = await _jellyfinDbProvider.CreateDbContextAsync().ConfigureAwait(false);
await using (dbContext.ConfigureAwait(false))
{