Browse Source

fix adding alternate schedule (#1418)

pull/1419/head
Jason Dove 2 years ago committed by GitHub
parent
commit
8081845ef1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      CHANGELOG.md
  2. 7
      ErsatzTV.Application/Playouts/Commands/ReplacePlayoutAlternateScheduleItemsHandler.cs

1
CHANGELOG.md

@ -25,6 +25,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). @@ -25,6 +25,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- Fix log viewer crash when log file contains invalid data
- Clean channel guide cache on startup (delete channels that no longer exist)
- Fix Emby movie libraries so local file access is not required
- Fix adding alternate schedule
### Changed
- Optimize transcoding session to only work ahead (at max speed) for 2 minutes before throttling to realtime

7
ErsatzTV.Application/Playouts/Commands/ReplacePlayoutAlternateScheduleItemsHandler.cs

@ -119,6 +119,13 @@ public class ReplacePlayoutAlternateScheduleItemsHandler : @@ -119,6 +119,13 @@ public class ReplacePlayoutAlternateScheduleItemsHandler :
await dbContext.SaveChangesAsync(cancellationToken);
// load newly-added schedules
foreach (ProgramScheduleAlternate alternate in playout.ProgramScheduleAlternates
.Where(alternate => alternate.ProgramSchedule is null))
{
await dbContext.Entry(alternate).Reference(a => a.ProgramSchedule).LoadAsync(cancellationToken);
}
foreach (PlayoutItem _ in maybeLastPlayoutItem)
{
foreach (DateTimeOffset dayToCheck in daysToCheck)

Loading…
Cancel
Save