Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add operation to update liquidity pools #2720

Merged
merged 4 commits into from
Jan 29, 2023

Conversation

abitmore
Copy link
Member

@abitmore abitmore commented Jan 27, 2023

PR for #2604.

  • New operation: liquidity_pool_update_operation
    • operation_type = 75
    • default fee 1 BTS
     struct liquidity_pool_update_operation : public base_operation
     {
        asset                    fee;                ///< Operation fee
        account_id_type          account;            ///< The account who owns the liquidity pool
        liquidity_pool_id_type   pool;               ///< ID of the liquidity pool
        optional<uint16_t>       taker_fee_percent;       ///< Taker fee percent
        optional<uint16_t>       withdrawal_fee_percent;  ///< Withdrawal fee percent
        extensions_type extensions;  ///< Unused. Reserved for future use.
     };
    

Note:

  • The withdrawal fee percentage of a liquidity pool can be updated by the owner, but only to zero.
  • The taker fee percentage of a liquidity pool can be updated at any time by the owner if the withdrawal fee percentage is zero.

@abitmore abitmore linked an issue Jan 27, 2023 that may be closed by this pull request
17 tasks
@abitmore abitmore marked this pull request as ready for review January 28, 2023 11:34
@sonarcloud
Copy link

sonarcloud bot commented Jan 28, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 2 Code Smells

87.5% 87.5% Coverage
0.0% 0.0% Duplication

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow updating liquidity pool fee rates with certain restrictions
1 participant