Skip to content

Commit

Permalink
feat: make settlePool only callable by lps
Browse files Browse the repository at this point in the history
  • Loading branch information
bhargavaparoksham committed Jan 21, 2025
1 parent 3357598 commit 5a7f346
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/protocol/AssetPool.sol
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ contract AssetPool is IAssetPool, Ownable, Pausable {
* @notice Settle the pool if the rebalance window has expired and pool is not fully rebalanced.
* ToDo: Slash the LPs who didn't rebalance within the rebalance window, rebalance the pool and start the next cycle
*/
function settlePool() external {
function settlePool() external onlyLP {
if (cycleState != CycleState.REBALANCING) revert InvalidCycleState();
if (block.timestamp < nextRebalanceEndDate) revert RebalancingInProgress();

Expand Down

0 comments on commit 5a7f346

Please sign in to comment.