Merge pull request #10 from debris/fixed_mining

fixed mining condition
This commit is contained in:
Iuri Matias 2015-06-05 08:56:32 -04:00
commit d1dd25aa17
1 changed files with 2 additions and 2 deletions

View File

@ -10,9 +10,9 @@ setInterval(function() {
console.log("=== start mining"); console.log("=== start mining");
admin.miner.start(); 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 (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"); console.log("=== stop mining");
admin.miner.stop(); admin.miner.stop();
} }