Callback not called properly in _process for sync.
This commit is contained in:
parent
f2eaa1ae83
commit
c080a62958
@ -157,7 +157,6 @@ DB.prototype.start = function(callback) {
|
|||||||
mkdirp.sync(this.dataPath);
|
mkdirp.sync(this.dataPath);
|
||||||
}
|
}
|
||||||
|
|
||||||
self.genesis = Block.fromBuffer(self.bitcoind.genesisBuffer);
|
|
||||||
self._store = levelup(self.dataPath, { db: self.levelupStore, keyEncoding: 'binary', valueEncoding: 'binary'});
|
self._store = levelup(self.dataPath, { db: self.levelupStore, keyEncoding: 'binary', valueEncoding: 'binary'});
|
||||||
|
|
||||||
self.store = {
|
self.store = {
|
||||||
@ -170,6 +169,7 @@ DB.prototype.start = function(callback) {
|
|||||||
|
|
||||||
self.node.once('ready', function() {
|
self.node.once('ready', function() {
|
||||||
|
|
||||||
|
self.genesis = Block.fromBuffer(self.bitcoind.genesisBuffer);
|
||||||
self.loadTips(function(err) {
|
self.loadTips(function(err) {
|
||||||
|
|
||||||
if(err) {
|
if(err) {
|
||||||
|
|||||||
@ -260,6 +260,7 @@ BlockStream.prototype._getBlocks = function(heights, callback) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
self.push(null);
|
self.push(null);
|
||||||
|
callback();
|
||||||
|
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user