mirror of
https://github.com/stashapp/stash.git
synced 2025-12-15 21:03:22 +01:00
Don't retry failed autoplay (#4450)
This commit is contained in:
parent
95a2c8d13f
commit
08b73581a6
1 changed files with 1 additions and 8 deletions
|
|
@ -491,7 +491,6 @@ export const ScenePlayer: React.FC<IScenePlayerProps> = ({
|
|||
if (!player) return;
|
||||
|
||||
function onplay(this: VideoJsPlayer) {
|
||||
this.persistVolume().enabled = true;
|
||||
if (scene.interactive && interactiveReady.current) {
|
||||
interactiveClient.play(this.currentTime());
|
||||
}
|
||||
|
|
@ -767,13 +766,7 @@ export const ScenePlayer: React.FC<IScenePlayerProps> = ({
|
|||
return;
|
||||
}
|
||||
|
||||
player.play()?.catch(() => {
|
||||
// Browser probably blocking non-muted autoplay, so mute and try again
|
||||
player.persistVolume().enabled = false;
|
||||
player.muted(true);
|
||||
|
||||
player.play();
|
||||
});
|
||||
player.play();
|
||||
auto.current = false;
|
||||
}, [getPlayer, scene, ready, interactiveClient, currentScript]);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue