fix type error in update-metrics pt.2

This commit is contained in:
Pico2x 2022-09-12 21:25:45 +01:00
parent 86422f90ea
commit 4456a771fd

View File

@ -187,7 +187,7 @@ export async function updateMetricsCore() {
(e) => contractsById[e.contractId]
)
const bets = groupContracts.map((e) => {
if (e.id in betsByContract) {
if (e != null && e.id in betsByContract) {
return betsByContract[e.id] ?? []
} else {
return []