aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/daemon_handler.cpp
diff options
context:
space:
mode:
authorLee *!* Clagett <code@leeclagett.com>2024-06-24 19:57:20 -0400
committerLee *!* Clagett <code@leeclagett.com>2024-06-24 20:06:33 -0400
commitc5ad937cc11d3181b7549db573ac37ec635be96e (patch)
tree7990e5461bacf0e08feea5411addcc85990b39f0 /src/rpc/daemon_handler.cpp
parent24ccaba6ef429fdd37a3281c586e655987201a5c (diff)
downloadmonzero-core-c5ad937cc11d3181b7549db573ac37ec635be96e.tar.gz
monzero-core-c5ad937cc11d3181b7549db573ac37ec635be96e.tar.xz
monzero-core-c5ad937cc11d3181b7549db573ac37ec635be96e.zip
Fix ZMQ DaemonInfo:
* top_block_hash was never set in handler * wide_difficulty was never sent in JSON * wide_cumulative_difficulty was never sent in JSON
Diffstat (limited to 'src/rpc/daemon_handler.cpp')
-rw-r--r--src/rpc/daemon_handler.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/rpc/daemon_handler.cpp b/src/rpc/daemon_handler.cpp
index 11ab80666..b13663ac9 100644
--- a/src/rpc/daemon_handler.cpp
+++ b/src/rpc/daemon_handler.cpp
@@ -520,6 +520,8 @@ namespace rpc
res.info.target_height = res.info.height;
}
+ m_core.get_blockchain_top(res.info.top_block_height, res.info.top_block_hash);
+
auto& chain = m_core.get_blockchain_storage();
res.info.wide_difficulty = chain.get_difficulty_for_next_block();