Skip to content

Commit

Permalink
Merge pull request #30 from concero/master
Browse files Browse the repository at this point in the history
Fix parent pool complete deposit
  • Loading branch information
olegkron authored Dec 5, 2024
2 parents 3a839d9 + 399c73f commit c16c22b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
4 changes: 1 addition & 3 deletions contracts/ConceroBridge.sol
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ contract ConceroBridge is IConceroBridge, InfraCCIP {

/**
* @notice Function to calculate the proportional CCIP fee based on the amount
* @param ccipFeeInUsdc the total CCIP fee for a full batch (5000 USDC)
* @param ccipFeeInUsdc the total CCIP fee for a full batch
* @param amount the amount of USDC being transferred
*/
function _calculateProportionalCCIPFee(
Expand All @@ -257,5 +257,3 @@ contract ConceroBridge is IConceroBridge, InfraCCIP {
return (ccipFeeInUsdc * amount) / BATCHED_TX_THRESHOLD;
}
}

// broken tx concero id - 0x20abe54976b93ee76fc726f070b3626f9e7867bb855aa323981fcca1f2ec7efe
4 changes: 4 additions & 0 deletions contracts/ParentPool.sol
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ error NotOwner();
error OnlyRouterCanFulfill(address);
error Unauthorized();
error NotUsdcToken();
error DepositDeadlinePassed();

contract ParentPool is IParentPool, CCIPReceiver, ParentPoolCommon, ParentPoolStorage {
/* TYPE DECLARATIONS */
Expand Down Expand Up @@ -305,6 +306,9 @@ contract ParentPool is IParentPool, CCIPReceiver, ParentPoolCommon, ParentPoolSt
if (msg.sender != lpAddress) {
revert NotAllowedToCompleteDeposit();
}
if (block.timestamp > request.deadline) {
revert DepositDeadlinePassed();
}
if (childPoolsLiquiditySnapshot == 0) {
revert DepositRequestNotReady();
}
Expand Down

0 comments on commit c16c22b

Please sign in to comment.