Merge pull request #20851 from JoVictorNunes/fix-ext-video-starting-advanced
fix(external-video): player starting at an advanced point
This commit is contained in:
commit
45c144d435
@ -248,7 +248,8 @@ const ExternalVideoPlayer: React.FC<ExternalVideoPlayerProps> = ({
|
||||
|
||||
useEffect(() => {
|
||||
if (playerRef.current) {
|
||||
playerRef.current.seekTo(currentTime, 'seconds');
|
||||
const truncatedTime = currentTime < 1 ? 0 : currentTime;
|
||||
playerRef.current.seekTo(truncatedTime, 'seconds');
|
||||
}
|
||||
}, [playerRef.current, playing]);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user