aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/assets/player/shared/manager-options/manager-options-builder.ts
diff options
context:
space:
mode:
Diffstat (limited to 'client/src/assets/player/shared/manager-options/manager-options-builder.ts')
-rw-r--r--client/src/assets/player/shared/manager-options/manager-options-builder.ts6
1 files changed, 4 insertions, 2 deletions
diff --git a/client/src/assets/player/shared/manager-options/manager-options-builder.ts b/client/src/assets/player/shared/manager-options/manager-options-builder.ts
index 5dab1f7a9..29e851c1c 100644
--- a/client/src/assets/player/shared/manager-options/manager-options-builder.ts
+++ b/client/src/assets/player/shared/manager-options/manager-options-builder.ts
@@ -2,7 +2,7 @@ import videojs from 'video.js'
2import { copyToClipboard } from '@root-helpers/utils' 2import { copyToClipboard } from '@root-helpers/utils'
3import { buildVideoOrPlaylistEmbed } from '@root-helpers/video' 3import { buildVideoOrPlaylistEmbed } from '@root-helpers/video'
4import { isIOS, isSafari } from '@root-helpers/web-browser' 4import { isIOS, isSafari } from '@root-helpers/web-browser'
5import { buildVideoLink, decorateVideoLink } from '@shared/core-utils' 5import { buildVideoLink, decorateVideoLink, pick } from '@shared/core-utils'
6import { isDefaultLocale } from '@shared/core-utils/i18n' 6import { isDefaultLocale } from '@shared/core-utils/i18n'
7import { VideoJSPluginOptions } from '../../types' 7import { VideoJSPluginOptions } from '../../types'
8import { CommonOptions, PeertubePlayerManagerOptions, PlayerMode } from '../../types/manager-options' 8import { CommonOptions, PeertubePlayerManagerOptions, PlayerMode } from '../../types/manager-options'
@@ -49,8 +49,10 @@ export class ManagerOptionsBuilder {
49 49
50 if (this.mode === 'p2p-media-loader') { 50 if (this.mode === 'p2p-media-loader') {
51 const hlsOptionsBuilder = new HLSOptionsBuilder(this.options, this.p2pMediaLoaderModule) 51 const hlsOptionsBuilder = new HLSOptionsBuilder(this.options, this.p2pMediaLoaderModule)
52 const options = hlsOptionsBuilder.getPluginOptions()
52 53
53 Object.assign(plugins, hlsOptionsBuilder.getPluginOptions()) 54 Object.assign(plugins, pick(options, [ 'hlsjs', 'p2pMediaLoader' ]))
55 Object.assign(html5, options.html5)
54 } else if (this.mode === 'webtorrent') { 56 } else if (this.mode === 'webtorrent') {
55 const webtorrentOptionsBuilder = new WebTorrentOptionsBuilder(this.options, this.getAutoPlayValue(autoplay, alreadyPlayed)) 57 const webtorrentOptionsBuilder = new WebTorrentOptionsBuilder(this.options, this.getAutoPlayValue(autoplay, alreadyPlayed))
56 58