mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
cleanup and fix rpc call test
This commit is contained in:
committed by
Richard Holland
parent
f49dce56b0
commit
d492ffd04e
@@ -886,10 +886,8 @@ private:
|
||||
|
||||
// parse string
|
||||
Json::Value amountJson = jvParseSTAmount(jvParams[index].asString());
|
||||
// std::cout << "AMT JSON: " << amountJson << "\n";
|
||||
if (!amountJson) {
|
||||
// amount is string
|
||||
// std::cout << "IS STRING: " << "\n";
|
||||
if (!to_uint64(jvParams[index].asString()))
|
||||
return rpcError(rpcCHANNEL_AMT_MALFORMED);
|
||||
|
||||
@@ -898,7 +896,6 @@ private:
|
||||
else
|
||||
{
|
||||
// amount is json
|
||||
// std::cout << "IS JSON: " << "\n";
|
||||
STAmount amount;
|
||||
bool isAmount = amountFromJsonNoThrow(amount, amountJson);
|
||||
if (!isAmount)
|
||||
@@ -939,7 +936,6 @@ private:
|
||||
return rpcError(rpcCHANNEL_AMT_MALFORMED);
|
||||
// parse string
|
||||
Json::Value amountJson = jvParseSTAmount(jvParams[2u].asString());
|
||||
// std::cout << "AMT JSON: " << amountJson << "\n";
|
||||
if (!amountJson) {
|
||||
// amount is string
|
||||
if (!to_uint64(jvParams[2u].asString()))
|
||||
@@ -960,7 +956,6 @@ private:
|
||||
}
|
||||
|
||||
jvRequest[jss::signature] = jvParams[3u].asString();
|
||||
|
||||
return jvRequest;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user