From 6e5742d86d727c68b732f74f426a7aa10bfc2544 Mon Sep 17 00:00:00 2001 From: junderw Date: Thu, 31 Aug 2017 13:00:22 +0900 Subject: [PATCH] Fix txb.__overMaximumFees for segwit --- src/transaction_builder.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/transaction_builder.js b/src/transaction_builder.js index 776259c..e563c2e 100644 --- a/src/transaction_builder.js +++ b/src/transaction_builder.js @@ -648,7 +648,7 @@ TransactionBuilder.prototype.__build = function (allowIncomplete) { if (!allowIncomplete) { // do not rely on this, its merely a last resort - if (this.__overMaximumFees(tx.byteLength())) { + if (this.__overMaximumFees(tx.virtualSize())) { throw new Error('Transaction has absurd fees') } }