FeeDistributor
FeeDistributor receives fees from Pair and distributes them to the DAO wallet and Bribe. The owner can adjust the fee distribution rate to the DAO, the DAO wallet address, the Bribe contract address, and the associated pair.
setFeeRateToDao
Allows the owner to set the fee rate for DAO.
function setFeeRateToDao(
uint _feeRateToDao) external onlyOwnerParameters:
_feeRateToDao
uint
New fee rate for DAO, stored in 1e18.
setDaoWallet
Allows the owner to set the DAO wallet address.
function setDaoWallet(
address _daoWallet) external onlyOwnerParameters:
_daoWallet
address
New address for the DAO wallet.
setBribe
Allows the owner to set the Bribe contract address.
function setBribe(
address _bribe) external onlyOwnerParameters:
_bribe
address
New address for the Bribe contract.
setPair
Allows the owner to set the DysonPair contract address, along with the corresponding pair tokens.
function setPair(
address _pair) external onlyOwnerParameters:
_pair
address
New address for the DysonPair contract.
distributeFee
Distributes fees collected from the DysonPair to the DAO wallet and Bribe according to the feeRateToDao.
function distributeFee() external_calculateFee
Internal function to calculate the fee distribution to DAO and Bribe for a given token.
function _calculateFee(
address _token) internal view returns (uint feeToDAO, uint feeToBribe)Parameters:
_token
address
Address of the token.
Return Values:
feeToDAO
uint
Fee amount to be sent to the DAO.
feeToBribe
uint
Fee amount to be sent to the Bribe contract.
Last updated