Skip to content

Commit

Permalink
Reorg first tranche sanity check.
Browse files Browse the repository at this point in the history
  • Loading branch information
miohtama committed May 16, 2017
1 parent 6be0887 commit 4f421ac
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions contracts/EthTranchePricing.sol
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,6 @@ contract EthTranchePricing is PricingStrategy, Ownable {

uint highestAmount = 0;

// We need to start from zero
if(tranches[i].amount != 0) {
throw;
}

for(uint i=0; i<_tranches.length/2; i++) {
tranches[i].amount = _tranches[i*2];
tranches[i].price = _tranches[i*2+1];
Expand All @@ -67,6 +62,11 @@ contract EthTranchePricing is PricingStrategy, Ownable {
highestAmount = tranches[i].amount;
}

// We need to start from zero, otherwise we blow up our deployment
if(tranches[0].amount != 0) {
throw;
}

// Last tranche price must be zero, terminating the crowdale
if(tranches[trancheCount-1].price != 0) {
throw;
Expand Down

0 comments on commit 4f421ac

Please sign in to comment.