diff options
-rw-r--r-- | client/src/standalone/videos/shared/player-manager-options.ts | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/client/src/standalone/videos/shared/player-manager-options.ts b/client/src/standalone/videos/shared/player-manager-options.ts index 2eeb5ecac..9cebdcd10 100644 --- a/client/src/standalone/videos/shared/player-manager-options.ts +++ b/client/src/standalone/videos/shared/player-manager-options.ts | |||
@@ -6,6 +6,7 @@ import { | |||
6 | VideoCaption, | 6 | VideoCaption, |
7 | VideoDetails, | 7 | VideoDetails, |
8 | VideoPlaylistElement, | 8 | VideoPlaylistElement, |
9 | VideoState, | ||
9 | VideoStreamingPlaylistType | 10 | VideoStreamingPlaylistType |
10 | } from '../../../../../shared/models' | 11 | } from '../../../../../shared/models' |
11 | import { P2PMediaLoaderOptions, PeertubePlayerManagerOptions, PlayerMode, VideoJSCaption } from '../../../assets/player' | 12 | import { P2PMediaLoaderOptions, PeertubePlayerManagerOptions, PlayerMode, VideoJSCaption } from '../../../assets/player' |
@@ -108,6 +109,10 @@ export class PlayerManagerOptions { | |||
108 | const params = new URL(window.location.toString()).searchParams | 109 | const params = new URL(window.location.toString()).searchParams |
109 | 110 | ||
110 | this.autoplay = getParamToggle(params, 'autoplay', false) | 111 | this.autoplay = getParamToggle(params, 'autoplay', false) |
112 | // Disable auto play on live videos that are not streamed | ||
113 | if (video.state.id === VideoState.LIVE_ENDED || video.state.id === VideoState.WAITING_FOR_LIVE) { | ||
114 | this.autoplay = false | ||
115 | } | ||
111 | 116 | ||
112 | this.controls = getParamToggle(params, 'controls', true) | 117 | this.controls = getParamToggle(params, 'controls', true) |
113 | this.controlBar = getParamToggle(params, 'controlBar', true) | 118 | this.controlBar = getParamToggle(params, 'controlBar', true) |