From 46f7cd6837311019acef6e2086c7b006e6dbe1b9 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 12 Jul 2022 16:30:59 +0200 Subject: Fix handling broken lives We want the latest session that may already be finished --- server/lib/live/live-manager.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'server/lib') diff --git a/server/lib/live/live-manager.ts b/server/lib/live/live-manager.ts index 74f203091..206e30d7d 100644 --- a/server/lib/live/live-manager.ts +++ b/server/lib/live/live-manager.ts @@ -395,7 +395,7 @@ class LiveManager { const live = await VideoLiveModel.loadByVideoId(fullVideo.id) - const liveSession = liveSessionArg ?? await VideoLiveSessionModel.findCurrentSessionOf(fullVideo.id) + const liveSession = liveSessionArg ?? await VideoLiveSessionModel.findLatestSessionOf(fullVideo.id) // On server restart during a live if (!liveSession.endDate) { -- cgit v1.2.3