-
Notifications
You must be signed in to change notification settings - Fork 0
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
GLV pool #39
Comments
Need to add the functionality regarding to 1/4 of amount |
so add it up and finalise it with docs by tommorow . will have separate v2 and v1 branch for testnet |
@shivasai780 when it will be done... |
This Solidity contract, named GLV, serves as a vault for receiving and storing funds from the Burning contract for a specific protocol. The contract allows the Burning contract to deposit funds into it, tracks the accumulated amounts for different protocols, and enables the foundation to interact with certain functions. Here's a detailed breakdown of its features: Contract Overview: The GlipsVault contract acts as an intermediary between the Burning contract, associated protocols, and a minting pool. It's used to securely manage and distribute funds for a particular protocol. Modifiers: OnlyBurning: This modifier ensures that only the Burning contract is allowed to call the function it's applied to. OnlyWeuFoundation: This modifier ensures that only the specified foundation (WeuFoundation) is allowed to call the function it's applied to. ProtocolAmount: A mapping that stores the accumulated amounts for each protocol. The keys are protocol addresses, and the values represent the total amount of funds received for that protocol. BurningPool: The address of the Burning contract that is allowed to interact with this vault. ProtocolAddress: The address of the associated protocol for which funds are being managed. WeuFoundation: The address of the foundation that manages the contract and has permission to call certain functions. MintingPool: The address of the minting pool contract associated with this vault. Functions: initialize(...): This function is used to initialize the contract with essential addresses. It can only be called by the Burning contract. It sets the addresses of the Burning contract, the associated protocol, the foundation managing the contract, and the minting pool. ReceiveAmount(...): This function allows the Burning contract to deposit funds for a specific protocol. The protocol address, amount, and the USD token used are specified as arguments. The function checks the allowance of the contract and then transfers the funds from the Burning contract to the vault. It updates the accumulated amount for the protocol. sendAmount(...): This function sends a quarter of the accumulated funds for the associated protocol back to the Burning contract. Additionally, it decreases the maximum minted amount in the Minting contract by the sent amount. This function helps manage the balance of funds and prevents over-minting. The GLV contract provides a mechanism for safely handling and distributing funds between the Burning contract, protocols, and the minting pool. Its functionality is geared towards maintaining proper fund management and preventing unauthorized access to key actions. |
Its GLV - Generation Lineage Vault . |
hey @shivasai780 no changes being made... |
The text was updated successfully, but these errors were encountered: