aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorAjay <[email protected]>2023-10-18 12:13:11 -0400
committerAjay <[email protected]>2023-10-18 12:13:11 -0400
commitc8c141f5c9f0082863d9c3304c0cad17fe394b84 (patch)
tree137e1c1ac4ae6d8371e9e5f2b69399bef561bb12
parent88cfa023c9248097042445228007558a101fc0f0 (diff)
downloadSponsorBlock-c8c141f5c9f0082863d9c3304c0cad17fe394b84.tar.gz
SponsorBlock-c8c141f5c9f0082863d9c3304c0cad17fe394b84.zip
Round end time when skipping on firefox if close
Fix #1883
-rw-r--r--src/content.ts3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/content.ts b/src/content.ts
index 0d5cc33a..de537005 100644
--- a/src/content.ts
+++ b/src/content.ts
@@ -1660,6 +1660,9 @@ function skipToTime({v, skipTime, skippingSegments, openNotice, forceAutoSkip, u
// MacOS will loop otherwise #1027
// Sometimes playlists loop too #1804
v.currentTime = v.duration - 0.001;
+ } else if (v.duration > 1 && Math.abs(skipTime[1] - v.duration) < 0.5
+ && isFirefoxOrSafari() && !isSafari()) {
+ v.currentTime = v.duration;
} else {
if (inMuteSegment(skipTime[1], true)) {
// Make sure not to mute if skipping into a mute segment