diff --git a/ethereum/contracts/core/ValidationPools.sol b/ethereum/contracts/core/ValidationPools.sol index 0ffdc29..77e6800 100644 --- a/ethereum/contracts/core/ValidationPools.sol +++ b/ethereum/contracts/core/ValidationPools.sol @@ -230,9 +230,6 @@ contract ValidationPools is Reputation, Forum { // Here we assume a stakeForAuthor ratio of 0.5 // TODO: Make stakeForAuthor an adjustable parameter totalRewards += pool.minted / 2; - if (pool.minted % 2 != 0) { - totalRewards += 1; - } // Include the losign portion of the VP initial stake // Issue rewards to the winners for (uint i = 0; i < pool.stakeCount; i++) { @@ -250,9 +247,13 @@ contract ValidationPools is Reputation, Forum { } // Due to rounding, there may be some excess REP. Award it to the author. uint remainder = totalRewards - totalAllocated; - + uint reward = pool.minted / 2 + remainder; + if (pool.minted % 2 != 0) { + // We staked the odd remainder in favor of the post, on behalf of the author. + reward += 1; + } // Transfer REP to the forum instead of to the author directly - _onValidatePost(pool.postIndex, pool.minted / 2 + remainder); + _onValidatePost(pool.postIndex, reward); } else { // If vote does not pass, divide the losing stake among the winners totalRewards += pool.minted;