From e33a6409d3a527c43841fd360b6501faf1b3112f Mon Sep 17 00:00:00 2001 From: Daniel Cousens Date: Wed, 4 Feb 2015 21:10:33 +1100 Subject: [PATCH] TxBuilder: add explanation for prevOutScript branch --- src/transaction_builder.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/transaction_builder.js b/src/transaction_builder.js index b8616dd..a33f786 100644 --- a/src/transaction_builder.js +++ b/src/transaction_builder.js @@ -302,6 +302,7 @@ TransactionBuilder.prototype.sign = function(index, privKey, redeemScript, hashT // initialize it } else { if (redeemScript) { + // if we have a prevOutScript, enforce scriptHash equality to the redeemScript if (input.prevOutScript) { assert.equal(input.prevOutType, 'scripthash', 'PrevOutScript must be P2SH')