http: fix block call.

This commit is contained in:
Christopher Jeffrey 2017-11-04 12:13:53 -07:00
parent bab42bbed8
commit 4ff93746a0
No known key found for this signature in database
GPG Key ID: 8962AB9DE6666BBD

View File

@ -279,9 +279,9 @@ HTTPServer.prototype.initRouter = function initRouter() {
}
const height = await this.chain.getHeight(hash);
const confirmations = this.chain.height - height;
const depth = this.chain.height - height + 1;
res.send(200, block.getJSON(this.network, view, height, confirmations));
res.send(200, block.getJSON(this.network, view, height, depth));
});
// Mempool snapshot