Don't rerun error if hls already tried

This commit is contained in:
Nicolas Mowen 2024-03-13 14:06:33 -06:00
parent fea09b51a8
commit fd89b3c0ed

View File

@ -181,6 +181,7 @@ export default function HlsVideoPlayer({
onEnded={onClipEnded}
onError={(e) => {
if (
!hlsRef.current &&
// @ts-expect-error code does exist
e.target.error.code == MediaError.MEDIA_ERR_SRC_NOT_SUPPORTED &&
videoRef.current