From 3b341c06db66ae675b37102e6c5d4009def1b48d Mon Sep 17 00:00:00 2001 From: Patrick Barron Date: Thu, 22 Feb 2024 09:43:55 -0500 Subject: [PATCH] Move TimerInfo start time logic out of RecordingHelper --- src/Jellyfin.LiveTv/Recordings/RecordingHelper.cs | 5 ----- src/Jellyfin.LiveTv/Timers/TimerManager.cs | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/src/Jellyfin.LiveTv/Recordings/RecordingHelper.cs b/src/Jellyfin.LiveTv/Recordings/RecordingHelper.cs index 1c8e2960be..2b75640451 100644 --- a/src/Jellyfin.LiveTv/Recordings/RecordingHelper.cs +++ b/src/Jellyfin.LiveTv/Recordings/RecordingHelper.cs @@ -7,11 +7,6 @@ namespace Jellyfin.LiveTv.Recordings { internal static class RecordingHelper { - public static DateTime GetStartTime(TimerInfo timer) - { - return timer.StartDate.AddSeconds(-timer.PrePaddingSeconds); - } - public static string GetRecordingName(TimerInfo info) { var name = info.Name; diff --git a/src/Jellyfin.LiveTv/Timers/TimerManager.cs b/src/Jellyfin.LiveTv/Timers/TimerManager.cs index 2e5003a537..da5deea36a 100644 --- a/src/Jellyfin.LiveTv/Timers/TimerManager.cs +++ b/src/Jellyfin.LiveTv/Timers/TimerManager.cs @@ -95,7 +95,7 @@ namespace Jellyfin.LiveTv.Timers return; } - var startDate = RecordingHelper.GetStartTime(item); + var startDate = item.StartDate.AddSeconds(-item.PrePaddingSeconds); var now = DateTime.UtcNow; if (startDate < now)