rpc: some more gbt fixes.
This commit is contained in:
parent
1a3dcbd277
commit
ff80620e5e
@ -1188,7 +1188,7 @@ RPC.prototype._createTemplate = co(function* _createTemplate(version, coinbase,
|
||||
dep = index[input.prevout.hash];
|
||||
if (dep != null && deps.indexOf(dep) === -1) {
|
||||
assert(dep < i);
|
||||
deps.push(dep);
|
||||
deps.push(dep + 1);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1264,7 +1264,9 @@ RPC.prototype._createTemplate = co(function* _createTemplate(version, coinbase,
|
||||
weightlimit: undefined,
|
||||
longpollid: this.chain.tip.rhash() + util.pad32(this.totalTX()),
|
||||
submitold: false,
|
||||
coinbaseaux: undefined,
|
||||
coinbaseaux: {
|
||||
flags: attempt.coinbaseFlags.toString('hex')
|
||||
},
|
||||
coinbasevalue: undefined,
|
||||
coinbasetxn: undefined,
|
||||
default_witness_commitment: undefined,
|
||||
@ -1304,9 +1306,6 @@ RPC.prototype._createTemplate = co(function* _createTemplate(version, coinbase,
|
||||
weight: tx.getWeight()
|
||||
};
|
||||
} else {
|
||||
json.coinbaseaux = {
|
||||
flags: attempt.coinbaseFlags.toString('hex')
|
||||
};
|
||||
json.coinbasevalue = attempt.getReward();
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user