Skip to content

Commit

Permalink
Merge pull request #169 from LefterisJP/fix_get_daily_payment
Browse files Browse the repository at this point in the history
Fix `getDailyPayment()` calculation
  • Loading branch information
CJentzsch committed May 24, 2016
2 parents dcb15dd + 4d0ae5d commit 01cc936
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions SampleOfferWithoutReward.sol
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,9 @@ contract SampleOfferWithoutRewards {
if (msg.sender != contractor)
throw;
uint amount = (now - dateOfSignature + 1 days) / (1 days) * dailyWithdrawLimit - paidOut;
if (amount > this.balance) {
amount = this.balance;
}
if (contractor.send(amount))
paidOut += amount;
}
Expand Down

0 comments on commit 01cc936

Please sign in to comment.