mirror of
https://github.com/Instadapp/aave-protocol-v2.git
synced 2024-07-29 21:47:30 +00:00
removed error from catch so it catches everything
This commit is contained in:
parent
acc2207d81
commit
f5f3adeb0f
|
@ -138,7 +138,7 @@ contract UiPoolDataProvider is IUiPoolDataProvider {
|
||||||
reserveData.aEmissionPerSecond = aEmissionPerSecond;
|
reserveData.aEmissionPerSecond = aEmissionPerSecond;
|
||||||
reserveData.aIncentivesLastUpdateTimestamp = aIncentivesLastUpdateTimestamp;
|
reserveData.aIncentivesLastUpdateTimestamp = aIncentivesLastUpdateTimestamp;
|
||||||
reserveData.aTokenIncentivesIndex = aTokenIncentivesIndex;
|
reserveData.aTokenIncentivesIndex = aTokenIncentivesIndex;
|
||||||
} catch Error(string memory /*reason*/) {}
|
} catch {}
|
||||||
|
|
||||||
try incentivesController.getAssetData(reserveData.variableDebtTokenAddress) returns (
|
try incentivesController.getAssetData(reserveData.variableDebtTokenAddress) returns (
|
||||||
uint256 vEmissionPerSecond, uint256 vIncentivesLastUpdateTimestamp, uint256 vTokenIncentivesIndex) {
|
uint256 vEmissionPerSecond, uint256 vIncentivesLastUpdateTimestamp, uint256 vTokenIncentivesIndex) {
|
||||||
|
@ -146,7 +146,7 @@ contract UiPoolDataProvider is IUiPoolDataProvider {
|
||||||
reserveData.vEmissionPerSecond = vEmissionPerSecond;
|
reserveData.vEmissionPerSecond = vEmissionPerSecond;
|
||||||
reserveData.vIncentivesLastUpdateTimestamp = vIncentivesLastUpdateTimestamp;
|
reserveData.vIncentivesLastUpdateTimestamp = vIncentivesLastUpdateTimestamp;
|
||||||
reserveData.vTokenIncentivesIndex = vTokenIncentivesIndex;
|
reserveData.vTokenIncentivesIndex = vTokenIncentivesIndex;
|
||||||
} catch Error(string memory /*reason*/) {}
|
} catch {}
|
||||||
|
|
||||||
try incentivesController.getAssetData(reserveData.stableDebtTokenAddress) returns (
|
try incentivesController.getAssetData(reserveData.stableDebtTokenAddress) returns (
|
||||||
uint256 sEmissionPerSecond, uint256 sIncentivesLastUpdateTimestamp, uint256 sTokenIncentivesIndex) {
|
uint256 sEmissionPerSecond, uint256 sIncentivesLastUpdateTimestamp, uint256 sTokenIncentivesIndex) {
|
||||||
|
@ -154,7 +154,7 @@ contract UiPoolDataProvider is IUiPoolDataProvider {
|
||||||
reserveData.sEmissionPerSecond = sEmissionPerSecond;
|
reserveData.sEmissionPerSecond = sEmissionPerSecond;
|
||||||
reserveData.sIncentivesLastUpdateTimestamp = sIncentivesLastUpdateTimestamp;
|
reserveData.sIncentivesLastUpdateTimestamp = sIncentivesLastUpdateTimestamp;
|
||||||
reserveData.sTokenIncentivesIndex = sTokenIncentivesIndex;
|
reserveData.sTokenIncentivesIndex = sTokenIncentivesIndex;
|
||||||
} catch Error(string memory /*reason*/) {}
|
} catch {}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (user != address(0)) {
|
if (user != address(0)) {
|
||||||
|
@ -166,7 +166,7 @@ contract UiPoolDataProvider is IUiPoolDataProvider {
|
||||||
) returns (
|
) returns (
|
||||||
uint256 aTokenincentivesUserIndex) {
|
uint256 aTokenincentivesUserIndex) {
|
||||||
userReservesData[i].aTokenincentivesUserIndex = aTokenincentivesUserIndex;
|
userReservesData[i].aTokenincentivesUserIndex = aTokenincentivesUserIndex;
|
||||||
} catch Error(string memory /*reason*/) {}
|
} catch {}
|
||||||
|
|
||||||
try incentivesController.getUserAssetData(
|
try incentivesController.getUserAssetData(
|
||||||
user,
|
user,
|
||||||
|
@ -174,7 +174,7 @@ contract UiPoolDataProvider is IUiPoolDataProvider {
|
||||||
) returns (
|
) returns (
|
||||||
uint256 vTokenincentivesUserIndex) {
|
uint256 vTokenincentivesUserIndex) {
|
||||||
userReservesData[i].vTokenincentivesUserIndex = vTokenincentivesUserIndex;
|
userReservesData[i].vTokenincentivesUserIndex = vTokenincentivesUserIndex;
|
||||||
} catch Error(string memory /*reason*/) {}
|
} catch {}
|
||||||
|
|
||||||
try incentivesController.getUserAssetData(
|
try incentivesController.getUserAssetData(
|
||||||
user,
|
user,
|
||||||
|
@ -182,7 +182,7 @@ contract UiPoolDataProvider is IUiPoolDataProvider {
|
||||||
) returns (
|
) returns (
|
||||||
uint256 sTokenincentivesUserIndex) {
|
uint256 sTokenincentivesUserIndex) {
|
||||||
userReservesData[i].sTokenincentivesUserIndex = sTokenincentivesUserIndex;
|
userReservesData[i].sTokenincentivesUserIndex = sTokenincentivesUserIndex;
|
||||||
} catch Error(string memory /*reason*/) {}
|
} catch {}
|
||||||
}
|
}
|
||||||
// user reserve data
|
// user reserve data
|
||||||
userReservesData[i].underlyingAsset = reserveData.underlyingAsset;
|
userReservesData[i].underlyingAsset = reserveData.underlyingAsset;
|
||||||
|
@ -219,9 +219,9 @@ contract UiPoolDataProvider is IUiPoolDataProvider {
|
||||||
|
|
||||||
uint256 unclaimedRewards;
|
uint256 unclaimedRewards;
|
||||||
if (address(0) != address(incentivesController)) {
|
if (address(0) != address(incentivesController)) {
|
||||||
// try incentivesController.getUserUnclaimedRewards(user) returns (uint256 rewards) {
|
try incentivesController.getUserUnclaimedRewards(user) returns (uint256 rewards) {
|
||||||
// unclaimedRewards = rewards;
|
unclaimedRewards = rewards;
|
||||||
// } catch Error (string memory) {}
|
} catch {}
|
||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
Loading…
Reference in New Issue
Block a user