refactor: improve async handling

This commit is contained in:
Carlos Valente
2025-02-15 14:05:53 +01:00
committed by Carlos Valente
parent c65761448d
commit 891bda6661
8 changed files with 88 additions and 87 deletions
+2 -2
View File
@@ -144,7 +144,7 @@ export const initAssets = async () => {
checkStart(OntimeStartOrder.InitAssets);
await clearUploadfolder();
populateStyles();
populateDemo();
await populateDemo();
const project = await initialiseProject();
logger.info(LogOrigin.Server, `Initialised Ontime with ${project}`);
};
@@ -200,7 +200,7 @@ export const startServer = async (
// initialise rundown service
const persistedRundown = getDataProvider().getRundown();
const persistedCustomFields = getDataProvider().getCustomFields();
initRundown(persistedRundown, persistedCustomFields);
await initRundown(persistedRundown, persistedCustomFields);
// initialise message service
messageService.init(eventStore.set, eventStore.get);