Fix type error in update-metrics

This commit is contained in:
Pico2x 2022-09-12 20:58:12 +01:00
parent ff81b859d1
commit 7d9908dbd0

View File

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