diff --git a/web/hooks/use-prob-changes.tsx b/web/hooks/use-prob-changes.tsx index a6f89a2a..3e0e1a1a 100644 --- a/web/hooks/use-prob-changes.tsx +++ b/web/hooks/use-prob-changes.tsx @@ -31,10 +31,10 @@ export const useProbChangesAlgolia = (userId: string) => { return { positiveChanges: positiveData.hits.filter( - (c) => c && c.probChanges.day > 0 + (c) => c.probChanges && c.probChanges.day > 0 ), negativeChanges: negativeData.hits.filter( - (c) => c && c.probChanges.day < 0 + (c) => c.probChanges && c.probChanges.day < 0 ), } }