mirror of
https://github.com/XRPLF/rippled.git
synced 2026-04-29 15:37:57 +00:00
fix: Peer crawler port field type inconsistency (#6318)
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: mvadari <8029314+mvadari@users.noreply.github.com> Co-authored-by: Mayukha Vadari <mvadari@gmail.com> Co-authored-by: Mayukha Vadari <mvadari@ripple.com> Co-authored-by: Bart <bthomee@users.noreply.github.com>
This commit is contained in:
@@ -721,13 +721,13 @@ OverlayImpl::getOverlayInfo()
|
||||
{
|
||||
using namespace std::chrono;
|
||||
Json::Value jv;
|
||||
auto& av = jv["active"] = Json::Value(Json::arrayValue);
|
||||
auto& av = jv[jss::active] = Json::Value(Json::arrayValue);
|
||||
|
||||
for_each([&](std::shared_ptr<PeerImp>&& sp) {
|
||||
auto& pv = av.append(Json::Value(Json::objectValue));
|
||||
pv[jss::public_key] = base64_encode(
|
||||
sp->getNodePublic().data(), sp->getNodePublic().size());
|
||||
pv[jss::type] = sp->slot()->inbound() ? "in" : "out";
|
||||
pv[jss::type] = sp->slot()->inbound() ? jss::in : jss::out;
|
||||
pv[jss::uptime] = static_cast<std::uint32_t>(
|
||||
duration_cast<seconds>(sp->uptime()).count());
|
||||
if (sp->crawl())
|
||||
@@ -740,7 +740,7 @@ OverlayImpl::getOverlayInfo()
|
||||
}
|
||||
else
|
||||
{
|
||||
pv[jss::port] = std::to_string(sp->getRemoteAddress().port());
|
||||
pv[jss::port] = sp->getRemoteAddress().port();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user