diff --git a/CHANGELOG.md b/CHANGELOG.md index 87618223b..072c2379e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). ### Fixed - Fix HLS Direct playback with Jellyfin 10.11 - Fix remote stream scripts (parsing issue with spaces and quotes) +- Fix block history being removed when it is still needed for mirror channel + - This caused playout build errors like "Unable to locate history for playout item" ## [25.8.0] - 2025-10-26 ### Added diff --git a/ErsatzTV.Application/Playouts/Commands/BuildPlayoutHandler.cs b/ErsatzTV.Application/Playouts/Commands/BuildPlayoutHandler.cs index ec4d86a64..f6ea6b8db 100644 --- a/ErsatzTV.Application/Playouts/Commands/BuildPlayoutHandler.cs +++ b/ErsatzTV.Application/Playouts/Commands/BuildPlayoutHandler.cs @@ -367,8 +367,8 @@ public class BuildPlayoutHandler : IRequestHandler allItemsToDelete = referenceData.PlayoutHistory .GroupBy(h => h.Key) .SelectMany(group => group - .Filter(h => h.Finish < start.UtcDateTime) + .Filter(h => h.Finish < start.UtcDateTime - referenceData.MaxPlayoutOffset) .OrderByDescending(h => h.Finish) .Tail());