diff --git a/client/src/app/+videos/+video-watch/video-watch.component.ts b/client/src/app/+videos/+video-watch/video-watch.component.ts index 2524d0216..5485b3ec5 100644 --- a/client/src/app/+videos/+video-watch/video-watch.component.ts +++ b/client/src/app/+videos/+video-watch/video-watch.component.ts @@ -695,6 +695,8 @@ export class VideoWatchComponent implements OnInit, OnDestroy { } const getStartTime = () => { + if (video.isLive) return undefined + const byUrl = urlOptions.startTime !== undefined const byHistory = video.userHistory && (!this.playlist || urlOptions.resume !== undefined) const byLocalStorage = getStoredVideoWatchHistory(video.uuid) diff --git a/client/src/assets/player/shared/peertube/peertube-plugin.ts b/client/src/assets/player/shared/peertube/peertube-plugin.ts index a63053242..0ca5a500a 100644 --- a/client/src/assets/player/shared/peertube/peertube-plugin.ts +++ b/client/src/assets/player/shared/peertube/peertube-plugin.ts @@ -409,10 +409,13 @@ class PeerTubePlugin extends Plugin { // Prefer canplaythrough instead of canplay because Chrome has issues with the second one this.player.one('canplaythrough', () => { - const startTime = this.options.startTime() || 0 - debugLogger('Start the video at ' + startTime) + const startTime = this.options.startTime() - this.player.currentTime(timeToInt(startTime)) + if (startTime !== null && startTime !== undefined) { + debugLogger('Start the video at ' + startTime) + + this.player.currentTime(timeToInt(startTime)) + } if (this.options.stopTime()) { const stopTime = timeToInt(this.options.stopTime())