mirror of https://github.com/oxen-io/lokinet
make format
This commit is contained in:
parent
8628212269
commit
0ecdda7a89
|
@ -86,15 +86,14 @@ namespace llarp
|
|||
if (m_peerDb)
|
||||
peerStatsObj = m_peerDb->ExtractStatus();
|
||||
|
||||
return util::StatusObject{
|
||||
{"running", true},
|
||||
{"numNodesKnown", _nodedb->num_loaded()},
|
||||
{"dht", _dht->impl->ExtractStatus()},
|
||||
{"services", _hiddenServiceContext.ExtractStatus()},
|
||||
{"exit", _exitContext.ExtractStatus()},
|
||||
{"links", _linkManager.ExtractStatus()},
|
||||
{"outboundMessages", _outboundMessageHandler.ExtractStatus()},
|
||||
{"peerStats", peerStatsObj}};
|
||||
return util::StatusObject{{"running", true},
|
||||
{"numNodesKnown", _nodedb->num_loaded()},
|
||||
{"dht", _dht->impl->ExtractStatus()},
|
||||
{"services", _hiddenServiceContext.ExtractStatus()},
|
||||
{"exit", _exitContext.ExtractStatus()},
|
||||
{"links", _linkManager.ExtractStatus()},
|
||||
{"outboundMessages", _outboundMessageHandler.ExtractStatus()},
|
||||
{"peerStats", peerStatsObj}};
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -51,7 +51,6 @@ namespace llarp
|
|||
{
|
||||
struct Router final : public AbstractRouter
|
||||
{
|
||||
|
||||
llarp_time_t _lastPump = 0s;
|
||||
bool ready;
|
||||
// transient iwp encryption key
|
||||
|
|
|
@ -163,9 +163,8 @@ namespace tooling
|
|||
llarp::AbstractRouter*
|
||||
RouterHive::GetRelay(const llarp::RouterID& id, bool needMutexLock)
|
||||
{
|
||||
auto guard = needMutexLock
|
||||
? std::make_optional<std::lock_guard<std::mutex>>(routerMutex)
|
||||
: std::nullopt;
|
||||
auto guard =
|
||||
needMutexLock ? std::make_optional<std::lock_guard<std::mutex>>(routerMutex) : std::nullopt;
|
||||
|
||||
auto itr = relays.find(id);
|
||||
if (itr == relays.end())
|
||||
|
|
|
@ -17,7 +17,7 @@ namespace llarp
|
|||
{
|
||||
struct Context;
|
||||
struct AbstractRouter;
|
||||
}
|
||||
} // namespace llarp
|
||||
|
||||
namespace tooling
|
||||
{
|
||||
|
@ -30,9 +30,7 @@ namespace tooling
|
|||
StartRouters(bool isRelay);
|
||||
|
||||
void
|
||||
AddRouter(
|
||||
const std::shared_ptr<llarp::Config>& config,
|
||||
bool isRelay);
|
||||
AddRouter(const std::shared_ptr<llarp::Config>& config, bool isRelay);
|
||||
|
||||
/// safely visit router
|
||||
void
|
||||
|
|
Loading…
Reference in New Issue