mirror of
https://github.com/Instadapp/aave-protocol-v2.git
synced 2024-07-29 21:47:30 +00:00
feat: hardcode maker
This commit is contained in:
parent
bed79c4691
commit
0b775af7a4
|
@ -28,6 +28,7 @@ contract UiPoolDataProvider is IUiPoolDataProvider {
|
||||||
IChainlinkAggregator public immutable networkBaseTokenPriceInUsdProxyAggregator;
|
IChainlinkAggregator public immutable networkBaseTokenPriceInUsdProxyAggregator;
|
||||||
IChainlinkAggregator public immutable marketReferenceCurrencyPriceInUsdProxyAggregator;
|
IChainlinkAggregator public immutable marketReferenceCurrencyPriceInUsdProxyAggregator;
|
||||||
uint256 public constant ETH_CURRENCY_UNIT = 1 ether;
|
uint256 public constant ETH_CURRENCY_UNIT = 1 ether;
|
||||||
|
address public constant MKRAddress = 0x9f8F72aA9304c8B593d555F12eF6589cC3A579A2;
|
||||||
|
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
|
@ -112,6 +113,14 @@ contract UiPoolDataProvider is IUiPoolDataProvider {
|
||||||
.scaledTotalSupply();
|
.scaledTotalSupply();
|
||||||
|
|
||||||
// we're getting this info from the aToken, because some of assets can be not compliant with ETC20Detailed
|
// we're getting this info from the aToken, because some of assets can be not compliant with ETC20Detailed
|
||||||
|
if (address(reserveData.underlyingAsset) == address(MKRAddress)) {
|
||||||
|
bytes32 symbol = IERC20DetailedBytes(reserveData.underlyingAsset).symbol();
|
||||||
|
reserveData.symbol = string(abi.encodePacked(symbol));
|
||||||
|
} else {
|
||||||
|
reserveData.symbol = IERC20Detailed(reserveData.underlyingAsset).symbol();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// (bool success, bytes memory result) = reserveData.underlyingAsset.staticcall(abi.encodeWithSignature("symbol()"));
|
// (bool success, bytes memory result) = reserveData.underlyingAsset.staticcall(abi.encodeWithSignature("symbol()"));
|
||||||
// reserveData.symbol = string(abi.encodePacked(result));
|
// reserveData.symbol = string(abi.encodePacked(result));
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user