Skip to content

Commit

Permalink
Merge pull request #10 from debris/fixed_mining
Browse files Browse the repository at this point in the history
fixed mining condition
  • Loading branch information
iurimatias committed Jun 5, 2015
2 parents 1430d02 + 29a28a6 commit d1dd25a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions js/mine.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ setInterval(function() {
console.log("=== start mining");
admin.miner.start();
}
else if (web3.eth.mining && minimalAmount && minimalAmount) {
else if (web3.eth.mining && minimalAmount && !pendingTransactions) {
if (minimalAmount) { console.log("=== minimal ether amount reached") }
if (pendingTransactions) { console.log("=== no pending transactions") }
if (!pendingTransactions) { console.log("=== no pending transactions") }
console.log("=== stop mining");
admin.miner.stop();
}
Expand Down

0 comments on commit d1dd25a

Please sign in to comment.