Skip to content

Commit

Permalink
fix(t2cr): both sides must pay all fees
Browse files Browse the repository at this point in the history
  • Loading branch information
eccentricexit committed Nov 20, 2018
1 parent 928ccd5 commit 096b353
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions contracts/standard/permission/ArbitrableTokenList.sol
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ contract ArbitrableTokenList is PermissionInterface, Arbitrable {
"Item does not have any pending requests"
);
require(
msg.value >= item.challengeReward + (arbitrator.arbitrationCost(arbitratorExtraData) / 2),
msg.value >= item.challengeReward + arbitrator.arbitrationCost(arbitratorExtraData),
"Not enough ETH."
);

Expand All @@ -191,13 +191,12 @@ contract ArbitrableTokenList is PermissionInterface, Arbitrable {
);

uint arbitrationCost = arbitrator.arbitrationCost(arbitratorExtraData);
uint costForSide = arbitrationCost / 2;
if (_party == Party.Submitter)
item.submitterFees += msg.value;
else
item.challengerFees += msg.value;

if (item.submitterFees >= costForSide && item.challengerFees >= costForSide) {
if (item.submitterFees >= arbitrationCost && item.challengerFees >= arbitrationCost) {
item.disputeID = arbitrator.createDispute.value(arbitrationCost)(2, arbitratorExtraData);
disputeIDToItem[item.disputeID] = _tokenID;
item.disputed = true;
Expand Down

0 comments on commit 096b353

Please sign in to comment.