aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/assets/player/p2p-media-loader
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-02-22 13:44:12 +0100
committerChocobozzz <me@florianbigard.com>2022-02-22 13:44:12 +0100
commitac5f679ad60fc48db6d9a9534a8ac5fd20eda36f (patch)
tree7acf66762539331129a70e45c2a40fadec74a3fd /client/src/assets/player/p2p-media-loader
parent89e3de8dc6dbe3c78aefb5f43e0feffd97b1af02 (diff)
downloadPeerTube-ac5f679ad60fc48db6d9a9534a8ac5fd20eda36f.tar.gz
PeerTube-ac5f679ad60fc48db6d9a9534a8ac5fd20eda36f.tar.zst
PeerTube-ac5f679ad60fc48db6d9a9534a8ac5fd20eda36f.zip
Fix HLS buffer
Diffstat (limited to 'client/src/assets/player/p2p-media-loader')
-rw-r--r--client/src/assets/player/p2p-media-loader/segment-url-builder.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/client/src/assets/player/p2p-media-loader/segment-url-builder.ts b/client/src/assets/player/p2p-media-loader/segment-url-builder.ts
index 5ddc81ff6..9d324078a 100644
--- a/client/src/assets/player/p2p-media-loader/segment-url-builder.ts
+++ b/client/src/assets/player/p2p-media-loader/segment-url-builder.ts
@@ -1,10 +1,10 @@
1import { Segment } from '@peertube/p2p-media-loader-core' 1import { Segment } from '@peertube/p2p-media-loader-core'
2import { RedundancyUrlManager } from './redundancy-url-manager' 2import { RedundancyUrlManager } from './redundancy-url-manager'
3 3
4function segmentUrlBuilderFactory (redundancyUrlManager: RedundancyUrlManager, requiredSegmentsPriority: number) { 4function segmentUrlBuilderFactory (redundancyUrlManager: RedundancyUrlManager, useOriginPriority: number) {
5 return function segmentBuilder (segment: Segment) { 5 return function segmentBuilder (segment: Segment) {
6 // Don't use redundancy for high priority segments 6 // Don't use redundancy for high priority segments
7 if (segment.priority <= requiredSegmentsPriority) return segment.url 7 if (segment.priority <= useOriginPriority) return segment.url
8 8
9 return redundancyUrlManager.buildUrl(segment.url) 9 return redundancyUrlManager.buildUrl(segment.url)
10 } 10 }