diff options
| author | Samantaz Fox <coding@samantaz.fr> | 2022-04-03 15:01:30 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-04-03 15:01:30 +0200 |
| commit | 0fa0e8e3f3eb987ce6e615937cf0c22344f859b9 (patch) | |
| tree | c58b881306533e5d615d503a53156d46a5b52ec1 | |
| parent | c152243b4d69191bcd672adbb55e7f7fb3c3ee2a (diff) | |
| parent | 2c22b0839f7dced5e82c1f1b23e040ea0849461d (diff) | |
| download | invidious-0fa0e8e3f3eb987ce6e615937cf0c22344f859b9.tar.gz invidious-0fa0e8e3f3eb987ce6e615937cf0c22344f859b9.tar.bz2 invidious-0fa0e8e3f3eb987ce6e615937cf0c22344f859b9.zip | |
Merge pull request #2990 from 138138138/master
Safari audio double duration fix for iOS 15
Diffstat (limited to '')
| -rw-r--r-- | assets/js/player.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/assets/js/player.js b/assets/js/player.js index a1a2cd16..74cdd987 100644 --- a/assets/js/player.js +++ b/assets/js/player.js @@ -675,8 +675,8 @@ if (player_data.preferred_caption_found) { if (navigator.vendor == "Apple Computer, Inc." && video_data.params.listen) { player.on('loadedmetadata', function () { player.on('timeupdate', function () { - if (player.remainingTime() < player.duration() / 2) { - player.currentTime(player.duration() + 1); + if (player.remainingTime() < player.duration() / 2 && player.remainingTime() >= 2) { + player.currentTime(player.duration() - 1); } }); }); |
