mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Tidy up rpc module:
* Move directory up to ripple/module/rpc * Use C++11 idioms and best practices
This commit is contained in:
committed by
Vinnie Falco
parent
27a4f44de5
commit
a23013abc1
@@ -20,13 +20,13 @@
|
||||
|
||||
namespace ripple {
|
||||
|
||||
Json::Value RPCHandler::doPrint (Json::Value params, Resource::Charge& loadType, Application::ScopedLockType& masterLockHolder)
|
||||
Json::Value doPrint (RPC::Context& context)
|
||||
{
|
||||
masterLockHolder.unlock ();
|
||||
context.lock_.unlock ();
|
||||
|
||||
JsonPropertyStream stream;
|
||||
if (params.isObject() && params["params"].isArray() && params["params"][0u].isString ())
|
||||
getApp().write (stream, params["params"][0u].asString());
|
||||
if (context.params_.isObject() && context.params_["params"].isArray() && context.params_["params"][0u].isString ())
|
||||
getApp().write (stream, context.params_["params"][0u].asString());
|
||||
else
|
||||
getApp().write (stream);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user