Skip to content

Commit

Permalink
fix undefined access
Browse files Browse the repository at this point in the history
  • Loading branch information
onnovisser committed Jun 5, 2024
1 parent 8e7be03 commit b43b196
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion centrifuge-app/src/pages/NavManagement/Overview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ export const NavOverviewCard = ({ poolId }: { poolId: string }) => {
const lastUpdatedSumBorrowedAmountByPeriod = dailyPoolStates?.find(
(state) => state.timestamp >= lastUpdated
)?.sumBorrowedAmountByPeriod
const todaySumBorrowedAmountByPeriod = dailyPoolStates?.[0].sumBorrowedAmountByPeriod
const todaySumBorrowedAmountByPeriod = dailyPoolStates?.[0]?.sumBorrowedAmountByPeriod
return lastUpdatedSumBorrowedAmountByPeriod && todaySumBorrowedAmountByPeriod
? new BN(todaySumBorrowedAmountByPeriod).sub(new BN(lastUpdatedSumBorrowedAmountByPeriod))
: new BN(0)
Expand Down

0 comments on commit b43b196

Please sign in to comment.