Skip to content

Conversation

@SynnekOG
Copy link

Pull Request

Summary

This PR introduces new admin functions to LiquidityManagerV2, enabling the contract owner to configure supported tokens, adjust protocol fees, and update the fee recipient. These changes strengthen protocol governance and provide flexibility in managing economic parameters.

Changes

  • LiquidityManagerV2
    • Added Admin Section Header with Natspec.
    • Added updateSupportedToken(token, supported):
      • Allows owner to enable/disable supported tokens.
      • Emits SupportedTokenUpdated event.
    • Added updateProtocolFee(newFee):
      • Updates protocol fee in basis points (capped at 10%).
    • Added updateProtocolFeeRecipient(newRecipient):
      • Updates the recipient of protocol fees.
      • Includes validation against the zero address.
  • Ran forge fmt for consistent formatting.

Motivation

  • Enables governance control over token whitelist management.
  • Provides flexibility to update protocol fee structure over time.
  • Ensures protocol revenue flows to the correct recipient.
  • Improves overall maintainability and security by isolating admin operations.

Next Steps

  • Add role-based access control (e.g., AccessControl) for finer-grained admin rights.
  • Emit events for updateProtocolFee and updateProtocolFeeRecipient for improved transparency.
  • Consider timelocks or multisig authorization for critical admin actions.

@2PykeETH 2PykeETH self-requested a review September 19, 2025 15:12
@2PykeETH 2PykeETH added documentation Improvements or additions to documentation enhancement New feature or request labels Sep 19, 2025
@2PykeETH 2PykeETH merged commit 295b048 into CraftMeme:main Sep 19, 2025
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants