diff options
author | victorsintnicolaas <vicsn@users.noreply.github.com> | 2018-06-13 22:38:26 +0200 |
---|---|---|
committer | victorsintnicolaas <vicsn@users.noreply.github.com> | 2018-06-29 10:06:18 +0200 |
commit | 9e1403e1556c58065bf415a507af06f19f3cfeda (patch) | |
tree | a41a7877481b071977f22e81ff4a71f081ee7baf /src/rpc/core_rpc_server.cpp | |
parent | add --regtest and --fixed-difficulty for regression testing (diff) | |
download | monero-9e1403e1556c58065bf415a507af06f19f3cfeda.tar.xz |
update get_info RPC and bump RPC version
Diffstat (limited to 'src/rpc/core_rpc_server.cpp')
-rw-r--r-- | src/rpc/core_rpc_server.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/rpc/core_rpc_server.cpp b/src/rpc/core_rpc_server.cpp index c0b1d8891..d06636ebf 100644 --- a/src/rpc/core_rpc_server.cpp +++ b/src/rpc/core_rpc_server.cpp @@ -194,6 +194,7 @@ namespace cryptonote res.mainnet = m_nettype == MAINNET; res.testnet = m_nettype == TESTNET; res.stagenet = m_nettype == STAGENET; + res.nettype = m_nettype == MAINNET ? "mainnet" : m_nettype == TESTNET ? "testnet" : m_nettype == STAGENET ? "stagenet" : "fakechain"; res.cumulative_difficulty = m_core.get_blockchain_storage().get_db().get_block_cumulative_difficulty(res.height - 1); res.block_size_limit = m_core.get_blockchain_storage().get_current_cumulative_blocksize_limit(); res.block_size_median = m_core.get_blockchain_storage().get_current_cumulative_blocksize_median(); @@ -1626,6 +1627,7 @@ namespace cryptonote res.mainnet = m_nettype == MAINNET; res.testnet = m_nettype == TESTNET; res.stagenet = m_nettype == STAGENET; + res.nettype = m_nettype == MAINNET ? "mainnet" : m_nettype == TESTNET ? "testnet" : m_nettype == STAGENET ? "stagenet" : "fakechain"; res.cumulative_difficulty = m_core.get_blockchain_storage().get_db().get_block_cumulative_difficulty(res.height - 1); res.block_size_limit = m_core.get_blockchain_storage().get_current_cumulative_blocksize_limit(); res.block_size_median = m_core.get_blockchain_storage().get_current_cumulative_blocksize_median(); |