From 14c07d34bef9de854813a0d05831fba04c9d5042 Mon Sep 17 00:00:00 2001 From: Arthur Britto Date: Sat, 2 Jun 2012 12:00:06 -0700 Subject: [PATCH] Fix RPC wallet_accounts. --- src/RPCServer.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/RPCServer.cpp b/src/RPCServer.cpp index d0fe93be2b..a6d31dac4f 100644 --- a/src/RPCServer.cpp +++ b/src/RPCServer.cpp @@ -945,7 +945,11 @@ Json::Value RPCServer::accounts(const uint256& uLedger, const NewcoinAddress& na AccountState::pointer as = mNetOps->getAccountState(uLedger, naAccount); if (as) { - as->addJson(jsonAccounts); + Json::Value jsonAccount(Json::objectValue); + + as->addJson(jsonAccount); + + jsonAccounts[naAccount.humanAccountID()] = jsonAccount; } else {