Skip to content

Commit d1dd25a

Browse files
committed
Merge pull request #10 from debris/fixed_mining
fixed mining condition
2 parents 1430d02 + 29a28a6 commit d1dd25a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

js/mine.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ setInterval(function() {
1010
console.log("=== start mining");
1111
admin.miner.start();
1212
}
13-
else if (web3.eth.mining && minimalAmount && minimalAmount) {
13+
else if (web3.eth.mining && minimalAmount && !pendingTransactions) {
1414
if (minimalAmount) { console.log("=== minimal ether amount reached") }
15-
if (pendingTransactions) { console.log("=== no pending transactions") }
15+
if (!pendingTransactions) { console.log("=== no pending transactions") }
1616
console.log("=== stop mining");
1717
admin.miner.stop();
1818
}

0 commit comments

Comments
 (0)