diff options
author | Chocobozzz <me@florianbigard.com> | 2022-07-12 16:30:59 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2022-07-12 16:30:59 +0200 |
commit | 46f7cd6837311019acef6e2086c7b006e6dbe1b9 (patch) | |
tree | ce5af18f6fd3e936494f97461276dae4d968c917 /server/lib | |
parent | 4ddb53f65d9d97fc3eb97d9dadcbbcf35d8ddab7 (diff) | |
download | PeerTube-46f7cd6837311019acef6e2086c7b006e6dbe1b9.tar.gz PeerTube-46f7cd6837311019acef6e2086c7b006e6dbe1b9.tar.zst PeerTube-46f7cd6837311019acef6e2086c7b006e6dbe1b9.zip |
Fix handling broken lives
We want the latest session that may already be finished
Diffstat (limited to 'server/lib')
-rw-r--r-- | server/lib/live/live-manager.ts | 2 |
1 files changed, 1 insertions, 1 deletions
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 { | |||
395 | 395 | ||
396 | const live = await VideoLiveModel.loadByVideoId(fullVideo.id) | 396 | const live = await VideoLiveModel.loadByVideoId(fullVideo.id) |
397 | 397 | ||
398 | const liveSession = liveSessionArg ?? await VideoLiveSessionModel.findCurrentSessionOf(fullVideo.id) | 398 | const liveSession = liveSessionArg ?? await VideoLiveSessionModel.findLatestSessionOf(fullVideo.id) |
399 | 399 | ||
400 | // On server restart during a live | 400 | // On server restart during a live |
401 | if (!liveSession.endDate) { | 401 | if (!liveSession.endDate) { |