From 6b25ffb90c229567046c99b7f39caf3990bb8721 Mon Sep 17 00:00:00 2001 From: Gerardo Nardelli Date: Mon, 22 Apr 2019 11:09:54 -0300 Subject: [PATCH] Update fee events logic on HomeBridgeErcToErc --- .../erc20_to_erc20/HomeBridgeErcToErc.sol | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/contracts/upgradeable_contracts/erc20_to_erc20/HomeBridgeErcToErc.sol b/contracts/upgradeable_contracts/erc20_to_erc20/HomeBridgeErcToErc.sol index 545617251..dca16d50a 100644 --- a/contracts/upgradeable_contracts/erc20_to_erc20/HomeBridgeErcToErc.sol +++ b/contracts/upgradeable_contracts/erc20_to_erc20/HomeBridgeErcToErc.sol @@ -15,8 +15,6 @@ import "../../IBlockReward.sol"; contract HomeBridgeErcToErc is ERC677Receiver, EternalStorage, BasicBridge, BasicHomeBridge, ERC677Bridge, OverdrawManagement, RewardableHomeBridgeErcToErc { event AmountLimitExceeded(address recipient, uint256 value, bytes32 transactionHash); - event FeeDistributedFromAffirmation(uint256 feeAmount, bytes32 indexed transactionHash); - event FeeDistributedFromSignatures(uint256 feeAmount, bytes32 indexed transactionHash); function initialize ( address _validatorContract, @@ -169,8 +167,7 @@ contract HomeBridgeErcToErc is ERC677Receiver, EternalStorage, BasicBridge, Basi address feeManager = feeManagerContract(); if (feeManager != address(0)) { uint256 fee = calculateFee(valueToMint, false, feeManager, FOREIGN_FEE); - distributeFeeFromAffirmation(fee, feeManager); - emit FeeDistributedFromAffirmation(fee, txHash); + distributeFeeFromAffirmation(fee, feeManager, txHash); valueToMint = valueToMint.sub(fee); } return erc677token().mint(_recipient, valueToMint); @@ -195,8 +192,7 @@ contract HomeBridgeErcToErc is ERC677Receiver, EternalStorage, BasicBridge, Basi address contractAddress; (recipient, amount, txHash, contractAddress) = Message.parseMessage(_message); uint256 fee = calculateFee(amount, true, feeManager, HOME_FEE); - distributeFeeFromSignatures(fee, feeManager); - emit FeeDistributedFromSignatures(fee, txHash); + distributeFeeFromSignatures(fee, feeManager, txHash); } }