reduce gas usage

This commit is contained in:
Ricardo Guilherme Schmidt 2018-04-13 15:33:12 -03:00
parent cf3bed0821
commit 6c4fd0651e
1 changed files with 1 additions and 1 deletions

View File

@ -175,12 +175,12 @@ contract MessageTribute is Controlled {
function getFee(address _from) internal view
returns (Fee)
{
Fee memory generalFee = feeCatalog[_from][address(0)];
Fee memory specificFee = feeCatalog[_from][msg.sender];
if (friendIndex[keccak256(msg.sender, _from)] > 0)
return Fee(0, false);
Fee memory generalFee = feeCatalog[_from][address(0)];
return specificFee.amount > 0 ? specificFee : generalFee;
}