Skip to content

Commit

Permalink
fix: one type
Browse files Browse the repository at this point in the history
  • Loading branch information
hieronx committed Sep 13, 2024
1 parent 7e52f73 commit a2524aa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/mappings/handlers/ethHandlers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ async function updateLoans(poolId: string, blockDate: Date, shelf: string, pile:
loan.totalRepaid
? (loan.totalRepaid += loan.repaidAmountByPeriod)
: (loan.totalRepaid = loan.repaidAmountByPeriod)
loan.repaysCount += 1
loan.repaysCount += BigInt(1)
}
if (
prevDebt * (loan.interestRatePerSec / BigInt(10) ** BigInt(27)) * BigInt(86400) <
Expand All @@ -363,7 +363,7 @@ async function updateLoans(poolId: string, blockDate: Date, shelf: string, pile:
loan.totalBorrowed
? (loan.totalBorrowed += loan.borrowedAmountByPeriod)
: (loan.totalBorrowed = loan.borrowedAmountByPeriod)
loan.borrowsCount += 1
loan.borrowsCount += BigInt(1)
}
logger.info(`Updating loan ${loan.id} for pool ${poolId}`)
await loan.save()
Expand Down

0 comments on commit a2524aa

Please sign in to comment.