Skip to content

Commit

Permalink
Merge branch 'main' into fix/spearbit-audit
Browse files Browse the repository at this point in the history
  • Loading branch information
clemlak authored Apr 3, 2024
2 parents 32f9862 + 90876e9 commit 1a3d7b1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/NTokenGeometricMean/NTokenGeometricMeanMath.sol
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,15 @@ function computeDeltaGivenDeltaLRoundUp(
uint256 deltaLiquidity,
uint256 totalLiquidity
) pure returns (uint256) {
return reserve.mulDivUp(deltaLiquidity, totalLiquidity);
return reserve.mulWadUp(deltaLiquidity.divWadUp(totalLiquidity));
}

function computeDeltaGivenDeltaLRoundDown(
uint256 reserve,
uint256 deltaLiquidity,
uint256 totalLiquidity
) pure returns (uint256) {
return reserve.mulDivDown(deltaLiquidity, totalLiquidity);
return reserve.mulWadDown(deltaLiquidity.divWadDown(totalLiquidity));
}

function computeL(
Expand Down

0 comments on commit 1a3d7b1

Please sign in to comment.