mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-14 03:43:50 +00:00
fix TimerPahse difference from load and reload (#1179)
* use loadEvent function to reload * rename reload to updateLoaded
This commit is contained in:
committed by
GitHub
parent
d3620b52f4
commit
dc06a9afc3
@@ -252,10 +252,10 @@ class RuntimeService {
|
||||
const onlyChangedNow = affectedIds?.length === 1 && affectedIds.at(0) === eventNow.id;
|
||||
|
||||
if (onlyChangedNow) {
|
||||
runtimeState.reload(eventNow);
|
||||
runtimeState.updateLoaded(eventNow);
|
||||
} else {
|
||||
const rundown = getRundown();
|
||||
runtimeState.reloadAll(rundown);
|
||||
runtimeState.updateAll(rundown);
|
||||
}
|
||||
return;
|
||||
}
|
||||
@@ -544,14 +544,9 @@ class RuntimeService {
|
||||
public reload() {
|
||||
const state = runtimeState.getState();
|
||||
if (state.eventNow) {
|
||||
const eventId = runtimeState.reload();
|
||||
if (eventId) {
|
||||
logger.info(LogOrigin.Playback, `Loaded event with ID ${eventId}`);
|
||||
process.nextTick(() => {
|
||||
integrationService.dispatch(TimerLifeCycle.onLoad);
|
||||
});
|
||||
}
|
||||
return this.loadEvent(state.eventNow);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user