diff --git a/lib/services/block/index.js b/lib/services/block/index.js index 58cbd8328..83002e6c6 100644 --- a/lib/services/block/index.js +++ b/lib/services/block/index.js @@ -1077,7 +1077,7 @@ BlockService.prototype._startSync = function() { this.on('next block', this._sync.bind(this)); this.on('synced', this._onSynced.bind(this)); clearInterval(this._reportInterval); - this._reportingInterval = setInterval(this._logProgress.bind(this), 5000); + this._reportInterval = setInterval(this._logProgress.bind(this), 5000); return this._sync(); } diff --git a/lib/services/mempool/index.js b/lib/services/mempool/index.js index a99601854..ad2f0d16f 100644 --- a/lib/services/mempool/index.js +++ b/lib/services/mempool/index.js @@ -30,6 +30,12 @@ util.inherits(MempoolService, BaseService); MempoolService.dependencies = ['db']; MempoolService.prototype.getAPIMethods = function() { + var methods = [ + ['getMempoolTransaction', this, this.getMempoolTransaction, 1], + ['getTxidsByAddress', this, this.getTxsByAddress, 2], + ]; + return methods; +}; MempoolService.prototype.subscribe = function(name, emitter) { this._subscriptions[name].push(emitter); @@ -43,12 +49,6 @@ MempoolService.prototype.unsubscribe = function(name, emitter) { } log.info(emitter.remoteAddress, 'unsubscribe:', 'mempool/' + name, 'total:', this._subscriptions[name].length); }; - var methods = [ - ['getMempoolTransaction', this, this.getMempoolTransaction, 1], - ['getTxidsByAddress', this, this.getTxsByAddress, 2], - ]; - return methods; -}; MempoolService.prototype.getPublishEvents = function() { return [