diff --git a/src/rpc/blockchain.cpp b/src/rpc/blockchain.cpp index 69b6194aa5..934a593bee 100644 --- a/src/rpc/blockchain.cpp +++ b/src/rpc/blockchain.cpp @@ -763,9 +763,11 @@ UniValue gettxout(const UniValue& params, bool fHelp) ret.push_back(Pair("confirmations", 0)); else ret.push_back(Pair("confirmations", pindex->nHeight - coins.nHeight + 1)); - if (coins.vout[n].nValue.IsAmount()) + if (coins.vout[n].nValue.IsAmount()) { ret.push_back(Pair("value", ValueFromAmount(coins.vout[n].nValue.GetAmount()))); - else {} // TODO: Non-Amount values + } else { + ret.push_back(Pair("valuecommitment", uint256(coins.vout[n].nValue.vchCommitment).GetHex())); + } UniValue o(UniValue::VOBJ); ScriptPubKeyToJSON(coins.vout[n].scriptPubKey, o, true); ret.push_back(Pair("scriptPubKey", o));