aboutsummaryrefslogtreecommitdiff
path: root/src/rest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/rest.cpp')
-rw-r--r--src/rest.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/rest.cpp b/src/rest.cpp
index f3195746ba..3142b25036 100644
--- a/src/rest.cpp
+++ b/src/rest.cpp
@@ -62,7 +62,7 @@ public:
};
extern void TxToJSON(const CTransaction& tx, const uint256 hashBlock, Object& entry);
-extern Object blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool txDetails = false);
+extern UniValue blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool txDetails = false);
extern void ScriptPubKeyToJSON(const CScript& scriptPubKey, Object& out, bool fIncludeHex);
static RestErr RESTERR(enum HTTPStatusCode status, string message)
@@ -221,7 +221,7 @@ static bool rest_block(AcceptedConnection* conn,
}
case RF_JSON: {
- Object objBlock = blockToJSON(block, pblockindex, showTxDetails);
+ UniValue objBlock = blockToJSON(block, pblockindex, showTxDetails);
string strJSON = objBlock.write() + "\n";
conn->stream() << HTTPReply(HTTP_OK, strJSON, fRun) << std::flush;
return true;
@@ -266,7 +266,7 @@ static bool rest_chaininfo(AcceptedConnection* conn,
switch (rf) {
case RF_JSON: {
UniValue rpcParams(UniValue::VARR);
- Value chainInfoObject = getblockchaininfo(rpcParams, false);
+ UniValue chainInfoObject = getblockchaininfo(rpcParams, false);
string strJSON = chainInfoObject.write() + "\n";
conn->stream() << HTTPReply(HTTP_OK, strJSON, fRun) << std::flush;
return true;