use [].reverse over prototype

This commit is contained in:
Daniel Cousens 2015-09-27 23:36:31 +10:00
parent 5c1c4589c0
commit 0b4c67406f
6 changed files with 7 additions and 8 deletions

View file

@ -172,8 +172,7 @@ TransactionBuilder.prototype.addInput = function (txHash, vout, sequence, prevOu
// is it a hex string?
if (typeof txHash === 'string') {
// transaction hashs's are displayed in reverse order, un-reverse it
txHash = new Buffer(txHash, 'hex')
Array.prototype.reverse.call(txHash)
txHash = [].reverse.call(new Buffer(txHash, 'hex'))
// is it a Transaction object?
} else if (txHash instanceof Transaction) {