bitcoind: return selected set of info for getinfo
This commit is contained in:
parent
3f34fb6ea0
commit
944c44ed74
|
@ -1631,8 +1631,20 @@ Bitcoin.prototype.getInfo = function(callback) {
|
||||||
return callback(self._wrapRPCError(err));
|
return callback(self._wrapRPCError(err));
|
||||||
}
|
}
|
||||||
var result = response.result;
|
var result = response.result;
|
||||||
result.network = self.node.getNetworkName();
|
var info = {
|
||||||
callback(null, result);
|
version: result.version,
|
||||||
|
protocolversion: result.protocolversion,
|
||||||
|
blocks: result.blocks,
|
||||||
|
timeoffset: result.timeoffset,
|
||||||
|
connections: result.connections,
|
||||||
|
proxy: result.proxy,
|
||||||
|
difficulty: result.difficulty,
|
||||||
|
testnet: result.testnet,
|
||||||
|
relayfee: result.relayfee,
|
||||||
|
errors: result.errors,
|
||||||
|
network: self.node.getNetworkName()
|
||||||
|
};
|
||||||
|
callback(null, info);
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue