From 071f8b1729ab76eac7045cc66c8ada60f2237d02 Mon Sep 17 00:00:00 2001 From: Ajay Ramachandran Date: Fri, 10 Dec 2021 23:52:50 -0500 Subject: [PATCH] Don't skip exactly to the end on Safari Fix #1027 --- src/content.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/content.ts b/src/content.ts index 76aa1f42..8eff6a7c 100644 --- a/src/content.ts +++ b/src/content.ts @@ -1225,6 +1225,9 @@ function skipToTime({v, skipTime, skippingSegments, openNotice, forceAutoSkip, u // for some reason you also can't skip to 1 second before the end if (v.loop && v.duration > 1 && skipTime[1] >= v.duration - 1) { v.currentTime = 0; + } else if (navigator.vendor === "Apple Computer, Inc." && v.duration > 1 && skipTime[1] >= v.duration - 1) { + // MacOS will loop otherwise #1027 + v.currentTime = skipTime[1] - 0.01; } else { v.currentTime = skipTime[1]; }