Refactors in anticipation of blinded values

This commit is contained in:
Luke Dashjr 2016-02-15 15:19:28 -08:00 committed by Gregory Sanders
parent 743081a205
commit b5f1b6dd38
34 changed files with 262 additions and 133 deletions

View file

@ -192,8 +192,10 @@ void TxToUniv(const CTransaction& tx, const uint256& hashBlock, UniValue& entry)
UniValue out(UniValue::VOBJ);
UniValue outValue(UniValue::VNUM, FormatMoney(txout.nValue));
out.pushKV("value", outValue);
if (txout.nValue.IsAmount()) {
UniValue outValue(UniValue::VNUM, FormatMoney(txout.nValue.GetAmount()));
out.pushKV("value", outValue);
}
out.pushKV("n", (int64_t)i);
UniValue o(UniValue::VOBJ);