Merge remote-tracking branch 'jellyfinorigin/master' into feature/pgsql_provider

This commit is contained in:
JPVenson
2025-02-05 18:32:13 +00:00
44 changed files with 3752 additions and 231 deletions

View File

@@ -645,7 +645,7 @@ public sealed class BaseItemRepository
// dto.MediaType = Enum.TryParse<MediaType>(entity.MediaType);
if (dto is IHasStartDate hasStartDate)
{
hasStartDate.StartDate = entity.StartDate;
hasStartDate.StartDate = entity.StartDate.GetValueOrDefault();
}
// Fields that are present in the DB but are never actually used
@@ -683,7 +683,7 @@ public sealed class BaseItemRepository
entity.ParentId = !dto.ParentId.IsEmpty() ? dto.ParentId : null;
entity.Path = GetPathToSave(dto.Path);
entity.EndDate = dto.EndDate.GetValueOrDefault();
entity.EndDate = dto.EndDate;
entity.CommunityRating = dto.CommunityRating;
entity.CustomRating = dto.CustomRating;
entity.IndexNumber = dto.IndexNumber;

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))
{

View File

@@ -194,6 +194,14 @@ public class TrickplayManager : ITrickplayManager
return;
}
// We support video backdrops, but we should not generate trickplay images for them
var parentDirectory = Directory.GetParent(mediaPath);
if (parentDirectory is not null && string.Equals(parentDirectory.Name, "backdrops", StringComparison.OrdinalIgnoreCase))
{
_logger.LogDebug("Ignoring backdrop media found at {Path} for item {ItemID}", mediaPath, video.Id);
return;
}
// The width has to be even, otherwise a lot of filters will not be able to sample it
var actualWidth = 2 * (width / 2);