Remove braces, fix benchmark and pass callback.
This commit is contained in:
parent
9020ddb85c
commit
b738a5fb84
@ -90,7 +90,7 @@ bitcoind.on('ready', function() {
|
|||||||
c = 0;
|
c = 0;
|
||||||
}
|
}
|
||||||
var hash = fixtureData.txHashes[c];
|
var hash = fixtureData.txHashes[c];
|
||||||
bitcoind.getTransaction(hash, function(err, tx) {
|
bitcoind.getTransaction(hash, true, function(err, tx) {
|
||||||
if (err) {
|
if (err) {
|
||||||
throw err;
|
throw err;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -328,12 +328,7 @@ Bitcoin.prototype.isSpent = function(txid, outputIndex) {
|
|||||||
};
|
};
|
||||||
|
|
||||||
Bitcoin.prototype.getTransaction = function(txid, queryMempool, callback) {
|
Bitcoin.prototype.getTransaction = function(txid, queryMempool, callback) {
|
||||||
return bitcoindjs.getTransaction(txid, queryMempool, function(err, tx) {
|
return bitcoindjs.getTransaction(txid, queryMempool, callback);
|
||||||
if (err) {
|
|
||||||
return callback(err);
|
|
||||||
}
|
|
||||||
return callback(null, tx);
|
|
||||||
});
|
|
||||||
};
|
};
|
||||||
|
|
||||||
Bitcoin.prototype.getTransactionWithBlock = function(txid, blockhash, callback) {
|
Bitcoin.prototype.getTransactionWithBlock = function(txid, blockhash, callback) {
|
||||||
|
|||||||
@ -804,8 +804,6 @@ async_get_tx(uv_work_t *req) {
|
|||||||
uint256 blockhash;
|
uint256 blockhash;
|
||||||
CTransaction ctx;
|
CTransaction ctx;
|
||||||
|
|
||||||
{
|
|
||||||
|
|
||||||
if (data->queryMempool) {
|
if (data->queryMempool) {
|
||||||
LOCK(cs_main);
|
LOCK(cs_main);
|
||||||
{
|
{
|
||||||
@ -839,8 +837,6 @@ async_get_tx(uv_work_t *req) {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user