Fix getTotalProtocolFeesThisEpoch by adding weth balance

This commit is contained in:
Amir Bandeali
2019-09-14 17:52:39 -05:00
parent e589f10e23
commit a2419ab31d

View File

@@ -44,7 +44,6 @@ contract MixinExchangeFees is
MixinExchangeManager,
MixinStakingPool
{
using LibSafeMath for uint256;
/// @dev Pays a protocol fee in ETH or WETH.
@@ -137,7 +136,8 @@ contract MixinExchangeFees is
view
returns (uint256)
{
return address(this).balance;
uint256 wethBalance = IEtherToken(WETH_ADDRESS).balanceOf(address(this));
return address(this).balance.safeAdd(wethBalance);
}
/// @dev Returns the amount of fees attributed to the input pool.