mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-17 21:24:11 +00:00
refactor: skip expected end if not playing
This commit is contained in:
committed by
Carlos Valente
parent
dd0dcfc2a2
commit
4fb9c42aef
@@ -115,7 +115,7 @@ export function updateRundownData(playableRundown: OntimeEvent[]) {
|
|||||||
|
|
||||||
runtimeState.runtime.plannedStart = firstEvent?.timeStart ?? null;
|
runtimeState.runtime.plannedStart = firstEvent?.timeStart ?? null;
|
||||||
runtimeState.runtime.plannedEnd = lastEvent?.timeEnd ?? null;
|
runtimeState.runtime.plannedEnd = lastEvent?.timeEnd ?? null;
|
||||||
if (runtimeState.runtime.plannedEnd === null) {
|
if (runtimeState.runtime.plannedEnd === null || !runtimeState.runtime.actualStart) {
|
||||||
runtimeState.runtime.expectedEnd = null;
|
runtimeState.runtime.expectedEnd = null;
|
||||||
} else {
|
} else {
|
||||||
runtimeState.runtime.expectedEnd = (runtimeState.runtime.plannedEnd + runtimeState.runtime.offset) % dayInMs;
|
runtimeState.runtime.expectedEnd = (runtimeState.runtime.plannedEnd + runtimeState.runtime.offset) % dayInMs;
|
||||||
|
|||||||
Reference in New Issue
Block a user