From 8b13af41f8729978307eb20dabd494489e3ce290 Mon Sep 17 00:00:00 2001 From: Adam Waldron Date: Thu, 29 Aug 2024 11:50:05 -0800 Subject: [PATCH] fix: allow vtt rollover with MPEGTS of 0 --- src/vtt-segment-loader.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/vtt-segment-loader.js b/src/vtt-segment-loader.js index c727088a0..f36ca98de 100644 --- a/src/vtt-segment-loader.js +++ b/src/vtt-segment-loader.js @@ -494,9 +494,7 @@ export default class VTTSegmentLoader extends SegmentLoader { segmentInfo.cues.forEach((cue) => { const duration = cue.endTime - cue.startTime; - const startTime = MPEGTS === 0 ? - cue.startTime + diff : - this.handleRollover_(cue.startTime + diff, mappingObj.time); + const startTime = this.handleRollover_(cue.startTime + diff, mappingObj.time); cue.startTime = Math.max(startTime, 0); cue.endTime = Math.max(startTime + duration, 0);