//SPDX-License-Identifier: MIT pragma solidity ^0.8.0; import "./ubeswap-farming/contracts/Owned.sol"; import "./IRevoFees.sol"; contract RevoFees is Owned, IRevoFees { uint256 public compounderFeeNumerator; uint256 public compounderFeeDenominator; uint256 public reserveFeeNumerator; uint256 public reserveFeeDenominator; constructor( address _owner, uint256 _compounderFeeNumerator, uint256 _compounderFeeDenominator, uint256 _reserveFeeNumerator, uint256 _reserveFeeDenominator ) Owned(_owner) { compounderFeeNumerator = _compounderFeeNumerator; compounderFeeDenominator = _compounderFeeDenominator; reserveFeeNumerator = _reserveFeeNumerator; reserveFeeDenominator = _reserveFeeDenominator; } function updateCompounderFee( uint256 _compounderFeeNumerator, uint256 _compounderFeeDenominator ) external onlyOwner { compounderFeeNumerator = _compounderFeeNumerator; compounderFeeDenominator = _compounderFeeDenominator; } function updateReserveFee( uint256 _reserveFeeNumerator, uint256 _reserveFeeDenominator ) external onlyOwner { reserveFeeNumerator = _reserveFeeNumerator; reserveFeeDenominator = _reserveFeeDenominator; } function compounderBonus(TokenAmount memory _interestAccrued) external pure override returns (TokenAmount[] memory output) { return new TokenAmount[](0); // intentionally returns empty list } function compounderFee(uint256 _interestAccrued) external view override returns (uint256) { return (_interestAccrued * compounderFeeNumerator) / compounderFeeDenominator; } function reserveFee(uint256 _interestAccrued) external view override returns (uint256) { return (_interestAccrued * reserveFeeNumerator) / reserveFeeDenominator; } function issueCompounderBonus(address recipient) external pure override { return; // intentionally does nothing } function withdrawalFee( uint256 interestEarnedNumerator, uint256 interestEarnedDenominator ) external pure override returns (uint256 feeNumerator, uint256 feeDenominator) { // 0.25% (ignores interest earned for simplicity) feeNumerator = 25; feeDenominator = 10000; } }