diff --git a/lib/services/bitcoind.js b/lib/services/bitcoind.js index 4108b8ef..3ffdc225 100644 --- a/lib/services/bitcoind.js +++ b/lib/services/bitcoind.js @@ -2006,6 +2006,19 @@ Bitcoin.prototype.getDetailedTransaction = function(txid, callback) { tx.nExpiryHeight = result.expiryheight; } + // Sapling START + if (tx.fOverwintered && tx.version >= 4) { + tx.valueBalance = result.valueBalance; + tx.spendDescs = result.vShieldedSpend; + tx.outputDescs = result.vShieldedOutput; + if (result.bindingSig) { + tx.bindingSig = result.bindingSig; + } + // Update tx.feeSatoshis with custom explorer JSON field 'valueBalanceZat' + tx.feeSatoshis = tx.feeSatoshis + result.valueBalanceZat; + } + // Sapling END + self.transactionDetailedCache.set(txid, tx); done(null, tx); });