mirror of
https://github.com/Stremio/stremio-web.git
synced 2026-03-11 17:15:48 +00:00
Merge pull request #975 from Stremio/fix/player-negative-number-from-stremio-video
Some checks failed
Build / build (push) Has been cancelled
Some checks failed
Build / build (push) Has been cancelled
fix: Player - TimeChanged & Seek time & duration now have Math.max(0, x)
This commit is contained in:
commit
665cf7dd2a
1 changed files with 4 additions and 4 deletions
|
|
@ -102,8 +102,8 @@ const usePlayer = (urlParams) => {
|
||||||
args: {
|
args: {
|
||||||
action: 'TimeChanged',
|
action: 'TimeChanged',
|
||||||
args: {
|
args: {
|
||||||
time: Math.round(time),
|
time: Math.max(0, Math.round(time)),
|
||||||
duration,
|
duration: Math.max(0, Math.round(duration)),
|
||||||
device,
|
device,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -118,8 +118,8 @@ const usePlayer = (urlParams) => {
|
||||||
args: {
|
args: {
|
||||||
action: 'Seek',
|
action: 'Seek',
|
||||||
args: {
|
args: {
|
||||||
time: Math.round(time),
|
time: Math.max(0, Math.round(time)),
|
||||||
duration,
|
duration: Math.max(0, Math.round(duration)),
|
||||||
device,
|
device,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue