fix: bms-table-sync shouldn't crash if any provided table is invalid

This commit is contained in:
zkldi
2022-12-22 10:15:46 +00:00
parent 4f68245cf1
commit d2f134bf0f
+6 -2
View File
@@ -161,8 +161,12 @@ export async function UpdateTable(tableInfo: BMSTableInfo) {
export async function SyncBMSTables() {
for (const table of BMS_TABLES) {
// eslint-disable-next-line no-await-in-loop
await UpdateTable(table);
try {
// eslint-disable-next-line no-await-in-loop
await UpdateTable(table);
} catch (err) {
logger.error(`Failed to update table ${table.name} (${table.url}).`, { err });
}
}
logger.info(`Re-initialising folder-chart-lookup, since changes may have been made.`);