aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonas Schnelli <jonas.schnelli@include7.ch>2015-05-27 09:41:14 +0200
committerJonas Schnelli <jonas.schnelli@include7.ch>2015-05-27 09:41:14 +0200
commit64b8027c5c8ad263c0f4cf2944fd3c59b08c3cd6 (patch)
tree24b9a92d3edd91e61df50772dfeca6e75992e9be
parent182686cdbd81c737922a296f582bfd8909dcdffc (diff)
rest.cpp: strip whitespace
-rw-r--r--src/rest.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/rest.cpp b/src/rest.cpp
index 1b7954bbf6..1426f21135 100644
--- a/src/rest.cpp
+++ b/src/rest.cpp
@@ -262,12 +262,12 @@ static bool rest_chaininfo(AcceptedConnection* conn,
{
vector<string> params;
const RetFormat rf = ParseDataFormat(params, strURIPart);
-
+
switch (rf) {
case RF_JSON: {
Array rpcParams;
Value chainInfoObject = getblockchaininfo(rpcParams, false);
-
+
string strJSON = write_string(chainInfoObject, false) + "\n";
conn->stream() << HTTPReply(HTTP_OK, strJSON, fRun) << std::flush;
return true;
@@ -276,7 +276,7 @@ static bool rest_chaininfo(AcceptedConnection* conn,
throw RESTERR(HTTP_NOT_FOUND, "output format not found (available: json)");
}
}
-
+
// not reached
return true; // continue to process further HTTP reqs on this cxn
}
@@ -351,9 +351,9 @@ static bool rest_getutxos(AcceptedConnection* conn,
// parse/deserialize input
// input-format = output-format, rest/getutxos/bin requires binary input, gives binary output, ...
-
+
string strRequestMutable = strRequest; //convert const string to string for allowing hex to bin converting
-
+
switch (rf) {
case RF_HEX: {
// convert hex to bin, continue then with bin part