Fix for broken block polling

This commit is contained in:
Matt 2014-02-26 18:37:12 -07:00
parent 54ef804c05
commit 5b0c39e840
3 changed files with 2 additions and 6 deletions

View File

@ -21,7 +21,7 @@ which are written in python. Compared to the spaghetti state of the latest
lower barrier to entry for other developers to fork and add features or fix bugs.
Features (need additional testing)
Features
----------------------------------
* Daemon RPC interface
* Stratum TCP socket server
@ -42,7 +42,6 @@ Features (need additional testing)
#### Under development
* P2P functionality for highly efficient block updates from daemon as a peer node
* Ability to use multiple daemons for block updates and submitting blocks
* Clustering to take advantage of multiple CPU cores
#### To do

View File

@ -336,7 +336,7 @@ var pool = module.exports = function pool(options, authorizeFn){
function SetupBlockPolling(){
if (typeof options.blockRefreshInterval === "number" && options.blockRefreshInterval > 0){
if (typeof options.blockRefreshInterval !== "number" || options.blockRefreshInterval <= 0){
emitLog('system', 'Block template polling has been disabled');
return;
}
@ -348,7 +348,6 @@ var pool = module.exports = function pool(options, authorizeFn){
if (error) {
emitErrorLog('system', "Block polling error getting block template for " + options.name)
}
});
}, pollingInterval);
@ -362,7 +361,6 @@ var pool = module.exports = function pool(options, authorizeFn){
if (error) {
callback(error);
} else {
var processedNewBlock = _this.jobManager.processTemplate(result, publicKeyBuffer);
if (processedNewBlock && options.varDiff.enabled)

View File

@ -228,7 +228,6 @@ var StratumClient = function(options){
method: "mining.set_difficulty",
params: [difficulty]//[512],
});
console.log('new diff sent ' + difficulty);
return true;