mirror of
https://github.com/zoriya/Kyoo.git
synced 2025-05-30 19:54:16 -04:00
Fix hls start position
This commit is contained in:
parent
09b146928c
commit
1dbee1d79f
@ -166,7 +166,7 @@ const Video = forwardRef<{ seek: (value: number) => void }, VideoProps>(function
|
|||||||
ref.current.src = source.uri;
|
ref.current.src = source.uri;
|
||||||
} else {
|
} else {
|
||||||
hls.attachMedia(ref.current);
|
hls.attachMedia(ref.current);
|
||||||
hls.startLoad(source.startPosition ?? 0);
|
hls.startLoad(source.startPosition ? source.startPosition / 1000 : 0);
|
||||||
hls.on(Hls.Events.ERROR, (_, d) => {
|
hls.on(Hls.Events.ERROR, (_, d) => {
|
||||||
if (!d.fatal || !hls?.media) return;
|
if (!d.fatal || !hls?.media) return;
|
||||||
console.warn("Hls error", d);
|
console.warn("Hls error", d);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user