aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/net.cpp
diff options
context:
space:
mode:
authorRoss Nicoll <[email protected]>2021-08-14 09:22:45 +0100
committerGitHub <[email protected]>2021-08-14 09:22:45 +0100
commit6336a3a994d85a1641856261b2151a4a6fb8bf2f (patch)
tree457a7c6a080b5e8993c734923c8a905e0bcf11ad /src/rpc/net.cpp
parentMerge pull request #2448 from patricklodder/1.14.4-fix-acceptblock (diff)
parentrpc: add feefilter to peers from getpeerinfo (diff)
downloaddiscoin-6336a3a994d85a1641856261b2151a4a6fb8bf2f.tar.xz
discoin-6336a3a994d85a1641856261b2151a4a6fb8bf2f.zip
Merge pull request #2451 from patricklodder/1.14.4-feefilter-rpc
rpc: add feefilter to peers from getpeerinfo
Diffstat (limited to 'src/rpc/net.cpp')
-rw-r--r--src/rpc/net.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/rpc/net.cpp b/src/rpc/net.cpp
index e1400914f..d092d47d4 100644
--- a/src/rpc/net.cpp
+++ b/src/rpc/net.cpp
@@ -16,6 +16,7 @@
#include "timedata.h"
#include "ui_interface.h"
#include "util.h"
+#include "utilmoneystr.h"
#include "utilstrencodings.h"
#include "version.h"
@@ -95,6 +96,7 @@ UniValue getpeerinfo(const JSONRPCRequest& request)
" \"inbound\": true|false, (boolean) Inbound (true) or Outbound (false)\n"
" \"addnode\": true|false, (boolean) Whether connection was due to addnode and is using an addnode slot\n"
" \"startingheight\": n, (numeric) The starting height (block) of the peer\n"
+ " \"feefilter\": \"decimal\", (string) The value of the last feefilter set by this peer, in DOGE\n"
" \"banscore\": n, (numeric) The ban score\n"
" \"synced_headers\": n, (numeric) The last header we have in common with this peer\n"
" \"synced_blocks\": n, (numeric) The last block we have in common with this peer\n"
@@ -157,6 +159,7 @@ UniValue getpeerinfo(const JSONRPCRequest& request)
obj.push_back(Pair("inbound", stats.fInbound));
obj.push_back(Pair("addnode", stats.fAddnode));
obj.push_back(Pair("startingheight", stats.nStartingHeight));
+ obj.push_back(Pair("feefilter", FormatMoney(stats.minFeeFilter)));
if (fStateStats) {
obj.push_back(Pair("banscore", statestats.nMisbehavior));
obj.push_back(Pair("synced_headers", statestats.nSyncHeight));