aboutsummaryrefslogtreecommitdiff
path: root/src/rpcmisc.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/rpcmisc.cpp')
-rw-r--r--src/rpcmisc.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/rpcmisc.cpp b/src/rpcmisc.cpp
index 15bbe90bc7..f5fc22aff1 100644
--- a/src/rpcmisc.cpp
+++ b/src/rpcmisc.cpp
@@ -20,9 +20,9 @@
#include <stdint.h>
#include <boost/assign/list_of.hpp>
-#include "json_spirit_wrapper.h"
-using namespace json_spirit;
+#include "univalue/univalue.h"
+
using namespace std;
/**
@@ -38,7 +38,7 @@ using namespace std;
*
* Or alternatively, create a specific query method for the information.
**/
-UniValue getinfo(const Array& params, bool fHelp)
+UniValue getinfo(const UniValue& params, bool fHelp)
{
if (fHelp || params.size() != 0)
throw runtime_error(
@@ -107,7 +107,7 @@ UniValue getinfo(const Array& params, bool fHelp)
}
#ifdef ENABLE_WALLET
-class DescribeAddressVisitor : public boost::static_visitor<Object>
+class DescribeAddressVisitor : public boost::static_visitor<UniValue>
{
private:
isminetype mine;
@@ -115,7 +115,7 @@ private:
public:
DescribeAddressVisitor(isminetype mineIn) : mine(mineIn) {}
- UniValue operator()(const CNoDestination &dest) const { return Object(); }
+ UniValue operator()(const CNoDestination &dest) const { return UniValue(UniValue::VOBJ); }
UniValue operator()(const CKeyID &keyID) const {
UniValue obj(UniValue::VOBJ);
@@ -153,7 +153,7 @@ public:
};
#endif
-UniValue validateaddress(const Array& params, bool fHelp)
+UniValue validateaddress(const UniValue& params, bool fHelp)
{
if (fHelp || params.size() != 1)
throw runtime_error(
@@ -215,10 +215,10 @@ UniValue validateaddress(const Array& params, bool fHelp)
/**
* Used by addmultisigaddress / createmultisig:
*/
-CScript _createmultisig_redeemScript(const Array& params)
+CScript _createmultisig_redeemScript(const UniValue& params)
{
int nRequired = params[0].get_int();
- const Array& keys = params[1].get_array();
+ const UniValue& keys = params[1].get_array();
// Gather public keys
if (nRequired < 1)
@@ -276,7 +276,7 @@ CScript _createmultisig_redeemScript(const Array& params)
return result;
}
-UniValue createmultisig(const Array& params, bool fHelp)
+UniValue createmultisig(const UniValue& params, bool fHelp)
{
if (fHelp || params.size() < 2 || params.size() > 2)
{
@@ -319,7 +319,7 @@ UniValue createmultisig(const Array& params, bool fHelp)
return result;
}
-UniValue verifymessage(const Array& params, bool fHelp)
+UniValue verifymessage(const UniValue& params, bool fHelp)
{
if (fHelp || params.size() != 3)
throw runtime_error(
@@ -373,7 +373,7 @@ UniValue verifymessage(const Array& params, bool fHelp)
return (pubkey.GetID() == keyID);
}
-UniValue setmocktime(const Array& params, bool fHelp)
+UniValue setmocktime(const UniValue& params, bool fHelp)
{
if (fHelp || params.size() != 1)
throw runtime_error(