rpc: reverse target endianness.
This commit is contained in:
parent
cb7af959ce
commit
c80c242738
@ -1678,9 +1678,7 @@ RPC.prototype.__template = co(function* _template(version, coinbase, rules) {
|
||||
vbrequired: 0,
|
||||
height: attempt.height,
|
||||
previousblockhash: util.revHex(block.prevBlock),
|
||||
// NOTE: The BIP says this is supposed
|
||||
// to be big-endian, which is _incorrect_.
|
||||
target: attempt.target.toString('hex'),
|
||||
target: util.revHex(attempt.target.toString('hex')),
|
||||
bits: util.hex32(block.bits),
|
||||
noncerange: '00000000ffffffff',
|
||||
curtime: block.ts,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user