From 46985f4ee7d1bbb410e20b5e8d4d8429fd4c2d33 Mon Sep 17 00:00:00 2001 From: Nicholas Frederiksen Date: Tue, 12 Sep 2023 16:35:13 +0200 Subject: [PATCH] Reset timeOffset when loading next vod --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index 0bf00e8..6fe314f 100644 --- a/index.js +++ b/index.js @@ -1932,7 +1932,7 @@ class HLSVod { } const lastSeg = this.segments[sourceBw][this.segments[sourceBw].length - 1]; if (this.timeOffset !== null && lastSeg && lastSeg.timelinePosition) { - this.timeOffset = lastSeg.timelinePosition + lastSeg.duration * 1000; + this.timeOffset += lastSeg.duration * 1000; } this.segments[destBw].push({ discontinuity: true,